public function unmarshal($value, $object = null, $params = []) { $id = $value["id"]; if (intval($id) > 0) { return Asset\Image::getById($id); } }