Skip to content

reloadSelf() override never calls super.reloadSelf(), so a reload reports success without reloading anything #20

Description

@wisdommen

Symptom

/ul reload (or the framework's own reload path) reports that this module's configuration was reloaded, but nothing is re-read: config entities keep their old values, the language catalogue is not re-created, and @ConditionalOnConfig drift is never reported.

Cause

src/main/java/com/ultikits/plugins/mail/UltiMail.java:34 overrides UltiToolsPlugin.reloadSelf() without calling super.reloadSelf():

    public void reloadSelf() {
        getLogger().info(i18n("UltiMail 配置已重载!"));
    }

The framework's reloadSelf() is what performs the reload — getConfigManager().reloadConfigs(this), then re-creating the language catalogue, then ConditionalRegistrationEvaluator.reportDrift(this) — and its javadoc states that an override which skips super loses all of it. This override keeps only the log line, so the success message is printed for work that did not happen.

Fix

Call super.reloadSelf() first, then log. Pin it with a test that fails when the call is removed and passes when it is restored — the same shape as the fixes already merged for the identical defect in UltiKits/UltiLogin#18 and UltiKits/UltiWorlds#16.

Context

One of nine modules with this exact override shape, measured 2026-09-06 across all sixteen module repositories. Tracked together, with a proposal to close the defect class in the framework itself, at UltiKits/UltiTools-Reborn#419. Not part of Phase 13 of the 6.3.0 milestone by maintainer decision (that phase closes the defects the ecosystem acceptance pass found; this one was found by a sweep afterwards).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions