HomePhabricator

Sanitize gadget name
a74e3a7dfa0eUnpublished

Unpublished Commit · Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

Sanitize gadget name

MediaWikiGadgetsDefinition does some basic gadget name sanitization
and we have to do the same when checking "is gadget enabled for user"

Changes:

  • sanitize gadget name same way as MediaWikiGadgetsDefinitionRepo::newFromDefinition() does.
  • add try{} catch() when loading gadget as getGadget might throw an exception

Bug: T160081
Change-Id: Ia7a57e9dcfa3b25129d6d2bf75795372fad2b251

Details

Provenance
polishdeveloperAuthored on Apr 10 2017, 10:27 PM
phuedxCommitted on Apr 12 2017, 8:39 AM
Parents
rEPOPf80acb978b3a: renderer: Pass event to behavior for processing
Branches
Unknown
Tags
Unknown
References
refs/changes/23/347523/3
ChangeId
Ia7a57e9dcfa3b25129d6d2bf75795372fad2b251