fixed invariant message on BaseModel::__get()