Exception: get_class(): Argument #1 ($object) must be of type object, string given