Skip to content
This repository has been archived by the owner on Nov 16, 2022. It is now read-only.

Commit

Permalink
Merge pull request #147 from davidyell/develop
Browse files Browse the repository at this point in the history
Merge for release
  • Loading branch information
davidyell committed Oct 7, 2015
2 parents d4ed23d + e0209a5 commit e14c8d5
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 18 deletions.
2 changes: 1 addition & 1 deletion .coveralls.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
src_dir: src
coverage_clover: build/logs/clover.xml
coverage_clover: build/logs/clover.xml
6 changes: 3 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ matrix:
fast_finish: true

include:
- php: 5.5
php: 5.5
env: PHPCS=1 DEFAULT=0

- php: 5.5
php: 5.5
env: COVERALLS=1 DEFAULT=0

install:
Expand All @@ -41,4 +41,4 @@ script:
- sh -c "if [ '$COVERALLS' = '1' ]; then php vendor/bin/coveralls -c .coveralls.yml -v; fi"

notifications:
email: false
email: false
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,11 @@ in a similar vein to how [@josegonzalez](https://github.com/josegonzalez) had wr
* [File Info is enabled](http://php.net/manual/en/book.fileinfo.php) for mimetype validation

##Status
This is currently in beta, the api is stable and the plugin is functionally complete.

[![Build Status](https://travis-ci.org/davidyell/CakePHP3-Proffer.svg?branch=master)](https://travis-ci.org/davidyell/CakePHP3-Proffer)
[![Coverage Status](https://coveralls.io/repos/davidyell/CakePHP3-Proffer/badge.png)](https://coveralls.io/r/davidyell/CakePHP3-Proffer)
[![Dependency Status](https://www.versioneye.com/user/projects/54eee43931e55e12f9000018/badge.svg?style=flat)](https://www.versioneye.com/user/projects/54eee43931e55e12f9000018)
[![Latest Stable Version](https://poser.pugx.org/davidyell/proffer/v/stable.svg)](https://packagist.org/packages/davidyell/proffer) [![Total Downloads](https://poser.pugx.org/davidyell/proffer/downloads.svg)](https://packagist.org/packages/davidyell/proffer) [![Latest Unstable Version](https://poser.pugx.org/davidyell/proffer/v/unstable.svg)](https://packagist.org/packages/davidyell/proffer) [![License](https://poser.pugx.org/davidyell/proffer/license.svg)](https://packagist.org/packages/davidyell/proffer)
[![SensioLabsInsight](https://insight.sensiolabs.com/projects/65daa950-3128-44ef-b388-d4370efd853c/mini.png)](https://insight.sensiolabs.com/projects/65daa950-3128-44ef-b388-d4370efd853c)

##Documentation
All the documentation can be found in the [docs](docs) folder.
Expand Down
1 change: 0 additions & 1 deletion src/Lib/ImageTransform.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@

namespace Proffer\Lib;

use Cake\Event\Event;
use Cake\ORM\Table;
use Imagine\Filter\Transformation;
use Imagine\Gd\Imagine as Gd;
Expand Down
2 changes: 0 additions & 2 deletions src/Lib/ImageTransformInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@

namespace Proffer\Lib;

use Cake\ORM\Table;

interface ImageTransformInterface
{
/**
Expand Down
3 changes: 0 additions & 3 deletions src/Lib/ProfferPathInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,6 @@

namespace Proffer\Lib;

use Cake\ORM\Entity;
use Cake\ORM\Table;

interface ProfferPathInterface
{

Expand Down
12 changes: 6 additions & 6 deletions src/Shell/ProfferShell.php
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ public function cleanup($table)
$okayToDestroy = $this->in(__('Are you sure? This will irreversibly delete files'), ['y', 'n'], 'n');
if ($okayToDestroy === 'N') {
$this->out(__('Aborted, no files deleted.'));
exit;
$this->_stop();
}
} else {
$this->out(__('<info>Performing dry run cleanup.</info>'));
Expand Down Expand Up @@ -257,12 +257,12 @@ protected function checkTable($table)
$this->Table = $this->loadModel($table);
} catch (Exception $e) {
$this->out(__('<error>' . $e->getMessage() . '</error>'));
exit;
$this->_stop();
}

if (get_class($this->Table) === 'AppModel') {
$this->out(__('<error>The table could not be found, instance of AppModel loaded.</error>'));
exit;
$this->_stop();
}

if (!$this->Table->hasBehavior('Proffer')) {
Expand All @@ -271,7 +271,7 @@ protected function checkTable($table)
"' does not have the Proffer behavior attached.</error>"
);
$this->out($out);
exit;
$this->_stop();
}

$config = $this->Table->behaviors()->Proffer->config();
Expand All @@ -282,15 +282,15 @@ protected function checkTable($table)
"' does not have the configured upload field in it's schema.</error>"
);
$this->out($out);
exit;
$this->_stop();
}
if (!$this->Table->hasField($settings['dir'])) {
$out = __(
"<error>The table '" . $this->Table->alias() .
"' does not have the configured dir field in it's schema.</error>"
);
$this->out($out);
exit;
$this->_stop();
}

}
Expand Down

0 comments on commit e14c8d5

Please sign in to comment.