Page MenuHomePhabricator

Fix JavaScript exception when having users with special names
ClosedPublic

Authored by sergey.vfx on Jan 22 2014, 9:56 AM.
Tags
None
Referenced Files
F14448281: D8037.id18181.diff
Thu, Dec 26, 4:22 PM
Unknown Object (File)
Mon, Dec 16, 12:07 PM
Unknown Object (File)
Sun, Dec 15, 5:22 PM
Unknown Object (File)
Thu, Dec 12, 11:04 PM
Unknown Object (File)
Wed, Dec 4, 10:08 AM
Unknown Object (File)
Nov 26 2024, 4:57 PM
Unknown Object (File)
Nov 18 2024, 9:53 PM
Unknown Object (File)
Nov 15 2024, 12:05 PM
Subscribers

Details

Summary

The issue was noticed in Firefox when user with login "watch"
was registered in the database. And it was caused by Object
in Firefox having "watch" method.

Solved by checking for whether lookup object does have own
property before using it as a map key.

Test Plan

To test the issue simply create a user with login "watch",
open the phabricator site in Firefox and try to assign any
maniphest task to this user. You'll see exception being
printed to the javascript console (in my case it's printed
to firebug console).

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped