do not store difficulty as author

This commit is contained in:
Thomas Rubini 2023-01-25 22:40:58 +01:00
parent 0c406c54af
commit 6f66a44e69
No known key found for this signature in database
GPG Key ID: C7D287C8C1CAC373

View File

@ -134,10 +134,10 @@ final class RecipeModel
return $this->A_INGREDIENTS;
}
public function getDifficulty(){
if($this->O_AUTHOR === null){
$this->O_AUTHOR = DifficultyModel::getByID($this->I_DIFFICULTY_ID);
if($this->O_DIFFICULTY === null){
$this->O_DIFFICULTY = DifficultyModel::getByID($this->I_DIFFICULTY_ID);
}
return $this->O_AUTHOR;
return $this->O_DIFFICULTY;
}
public function getApprs(){