https://bugzilla.wikimedia.org/show_bug.cgi?id=30914

       Web browser: ---
             Bug #: 30914
           Summary: user.tokens and user.options are implemented too late,
                    modules can't depend on them
           Product: MediaWiki
           Version: 1.19-svn
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: Unprioritized
         Component: Resource Loader
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected], [email protected],
                    [email protected]
    Classification: Unclassified


user.tokens and user.options are inlined all the way at the bottom of the page.
This is causing bugs when modules depend on user.tokens (which none do yet,
which is kind of bad when you think about it), because the following happens:

* loader resolves dependencies for foo
* loader loads foo|user.tokens
* mw.implement( 'user.tokens', ... ) is called
* foo is loaded normally and can use mw.user.tokens
* the inlined <script> tag call mw.implement( 'user.tokens', ... ) again,
resulting in an exception

There is no good reason for user.tokens and user.options to be inlined at the
/bottom/. We should inline them at the top, before the top-load queue.

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to