fix error when calling "registerOnLoadContent"