Fix AccountPage to have default form classes on initial page registration
Review Request #7103 — Created March 22, 2015 and submitted — Latest diff uploaded
When an extension uses
AccountPagesHook
with a pre-built list of forms (form_classes
), the listform_classes
is cleared when the extension'sAccountPage
is unregistered after the extension reloads. This causes the extension'sAccountPage
(s) to not show up in the account page after.This fix keeps track of the initial
form_classes
defined by theAccountPage
with_default_form_classes
, such that the original defined list ofform_classes
will be restored after an extension reload.
Wrote two unit tests which passed alongside existing tests. Also verified that an extension which uses
AccountPagesHook
still shows up in account pages after a reload.