/** * Removes a thumbnail from a media node. */ public function removeThumbnail() { $thumbnailValue = $this->Request->getRequiredParameter('thumbnailValue'); if ($thumbnailValue == $this->imagesThumbnailCmsSize) { $this->sendError('-1', 'This thumbnail cannot be removed because it is reserved for CMS use.'); return; } try { $nodeRef = $this->getNodeRef(); $this->MediaService->removeThumbnail($nodeRef, $thumbnailValue); $this->sendEmptyOK(); } catch (Exception $e) { $this->sendExceptionError($e); } }