Error: Call to undefined method Error::get(): Attempt to modify property "params" on null