Only run onUserSaveSettings hook if not in update.php

Depends on I57a47661f2069efb91340db8188be92d4efb23e9 in core.

Bug: 57335
Change-Id: I4cf977ee4e0dfd5c564334481e9ae2f6bca85b61
Merge "Only run onUserSaveSettings hook if not in update.php"