Craft\ImagerController::actionClearRemoteImages PHP Method

actionClearRemoteImages() public method

Controller action to clear remote images
    public function actionClearRemoteImages()
    {
        $key = craft()->request->getParam('key');
        $setKey = craft()->imager->getSetting('clearKey');
        if (!$setKey || $key != $setKey) {
            print_r('Unauthorized key');
            craft()->end();
        }
        craft()->imager->deleteRemoteImageCaches();
        if (craft()->request->getPost('redirect')) {
            $this->redirectToPostedUrl();
        }
        print_r('Your remote images cache was cleared!');
        craft()->end();
    }