/** * Sync up the list of tags in the database. * * @param Todos $todos * @param array $tags */ private function syncTags(Todos $todos, array $tags) { $todos->tags()->sync($tags); }