public function getTagIds() { return $this->tagIds !== null ? $this->tagIds : array_map(function ($tag) { return $tag->id; }, $this->tags); }