diff --git a/user_guide_src/source/models/entities.rst b/user_guide_src/source/models/entities.rst index 22a81e192784..623fc10bf7b0 100644 --- a/user_guide_src/source/models/entities.rst +++ b/user_guide_src/source/models/entities.rst @@ -153,7 +153,7 @@ Here's an updated User entity to provide some examples of how this could be used { public function setPassword(string $pass) { - $this->password = password_hash($pass, PASSWORD_BCRYPT); + $this->attributes['password'] = password_hash($pass, PASSWORD_BCRYPT); return $this; }