b8640ccb1d
onContentAfterSave and onContentChangeState fire for ALL content types in Joomla (articles, update sites, installer, etc). The legacy fallback used func_get_arg() without checking argument count, crashing when com_installer saved update sites (only 1 arg, not 3). Fix: check context early in the event object path, and guard legacy path with func_num_args() >= N before calling func_get_arg().