Last modified: 2013-10-16 05:49:01 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T54956, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 52956 - internal.loadTour() accesses definedTours properties without checking
internal.loadTour() accesses definedTours properties without checking
Status: NEW
Product: MediaWiki extensions
Classification: Unclassified
GuidedTour (Other open bugs)
master
All All
: Normal normal (vote)
: ---
Assigned To: Matthew Flaschen
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-08-17 06:01 UTC by spage
Modified: 2013-10-16 05:49 UTC (History)
4 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description spage 2013-08-17 06:01:06 UTC
internal.loadTour() failed for me with 
   TypeError: definedTours[tourName] is undefined
on ext.guidedTour.lib.js line 921
    condition: definedTours[tourName].showConditionally

I'm not sure how this happened, I think my -mw-tour cookie was out of sync with the modules it needed to load.  I'll try to reproduce, but it would be safer to test if ( definedTours[tourName] && gt.shouldShowTour( .... ) ).
Comment 1 Steven Walling 2013-10-16 05:24:43 UTC
Is this still happening anywhere?
Comment 2 Matthew Flaschen 2013-10-16 05:38:21 UTC
I think it is still possible in the code, but only applies to a broken or missing tour.  My comment at https://www.mediawiki.org/wiki/Extension:GuidedTour/Refactoring_brainstorming is relevant: "Should we only consider the the tour loaded when it calls defineTour (or with the step-by-step API, maybe something like finalizeDefinition?)"

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links