Permalink
Browse files

Fix coding standards errors.

  • Loading branch information...
markstory committed Aug 23, 2013
1 parent f88c33b commit 50cff13965ecb25c104821e6de6b0c22aac775e7
@@ -101,11 +101,11 @@ public function initialize(Component $Component) {
*/
public function build(array $config) {
if (empty($config['roles'])) {
throw new Error\AclException(__d('cake_dev','"roles" section not found in configuration.'));
throw new Error\AclException(__d('cake_dev', '"roles" section not found in configuration.'));
}
if (empty($config['rules']['allow']) && empty($config['rules']['deny'])) {
throw new Error\AclException(__d('cake_dev','Neither "allow" nor "deny" rules were provided in configuration.'));
throw new Error\AclException(__d('cake_dev', 'Neither "allow" nor "deny" rules were provided in configuration.'));
}
$rules['allow'] = !empty($config['rules']['allow']) ? $config['rules']['allow'] : array();
@@ -134,7 +134,7 @@ protected function _transformFunctionExpression(FunctionExpression $expression)
->name('')
->type('-')
->iterateParts(function($p) {
return new FunctionExpression('DATE', [$p['value']], [$p['type']]);
return new FunctionExpression('DATE', [$p['value']], [$p['type']]);
});
break;
case 'CURRENT_DATE':
@@ -11,7 +11,6 @@
*
* @copyright Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
* @link http://cakephp.org CakePHP(tm) Project
* @package Cake.Model
* @since CakePHP(tm) v 3.0.0
* @license MIT License (http://www.opensource.org/licenses/mit-license.php)
*/
@@ -22,7 +21,7 @@
class UnaryExpression extends QueryExpression {
/*
/**
* Converts the expression to its string representation
*
* @param Cake\Database\ValueBinder $generator Placeholder generator object
@@ -17,13 +17,13 @@
namespace Cake\Database;
use Cake\Database\Exception;
use Cake\Database\ValueBinder;
use Cake\Database\Expression\Comparison;
use Cake\Database\Expression\FunctionExpression;
use Cake\Database\Expression\OrderByExpression;
use Cake\Database\Expression\QueryExpression;
use Cake\Database\Expression\ValuesExpression;
use Cake\Database\Statement\CallbackStatement;
use Cake\Database\ValueBinder;
use Cake\Error;
use IteratorAggregate;
@@ -889,6 +889,7 @@ public function emailFormat($format = null) {
* @param string|AbstractTransport $name Either the name of a configured
* transport, or a transport instance.
* @return AbstractTransport|Cake\Network\Email\Email
* @throws Cake\Error\SocketException When the chosen transport lacks a send method.
*/
public function transport($name = null) {
if ($name === null) {
@@ -1097,6 +1098,8 @@ public function message($type = null) {
* an array of multiple transports to set.
* @param array|Closure|AbstractTransport Either an array of configuration
* data, a Closure factory function, or a transport instance.
* @return mixed Either null when setting or an array of data when reading.
* @throws Cake\Error\Exception When modifying an existing configuration.
*/
public static function configTransport($key, $config = null) {
if ($config === null && is_string($key)) {
@@ -1138,6 +1141,7 @@ public static function dropTransport($key) {
* or an array of multiple configuration profiles to set
* @param null|array $config Null to read config data, an array to set data.
* @return array|void
* @throws Cake\Error\Exception When modifying an existing configuration.
*/
public static function config($key, $config = null) {
// Read config.
@@ -16,8 +16,8 @@
*/
namespace Cake\ORM;
use Cake\Database\Type;
use Cake\Database\Exception;
use Cake\Database\Type;
use \Iterator;
use \JsonSerializable;
use \Serializable;
View
@@ -16,9 +16,9 @@
*/
namespace Cake\ORM;
use Cake\Database\Schema\Table as Schema;
use Cake\Event\Event;
use Cake\Event\EventManager;
use Cake\Database\Schema\Table as Schema;
use Cake\ORM\Association\BelongsTo;
use Cake\ORM\Association\BelongsToMany;
use Cake\ORM\Association\HasMany;
@@ -19,8 +19,8 @@
use Cake\Core\Configure;
use Cake\Core\Plugin;
use Cake\Log\Log;
use Cake\Network\Email\Email;
use Cake\Network\Email\DebugTransport;
use Cake\Network\Email\Email;
use Cake\TestSuite\TestCase;
use Cake\Utility\File;
@@ -840,7 +840,7 @@ public function testBufferResults() {
$this->assertInstanceOf('Cake\ORM\BufferedResultSet', $result);
}
/*
/**
* Tests that applying array options to a query will convert them
* to equivalent function calls with the correspondent array values
*
@@ -1197,7 +1197,7 @@ public function testAmpInText() {
* @return void
*/
public function testNoEntityLoading() {
$file = str_replace(' ' , '%20' , CAKE . 'VERSION.txt');
$file = str_replace(' ', '%20', CAKE . 'VERSION.txt');
$xml = <<<XML
<!DOCTYPE cakephp [
<!ENTITY payload SYSTEM "file://$file" >]>
View
@@ -12,8 +12,8 @@
* @license MIT License (http://www.opensource.org/licenses/mit-license.php)
*/
use Cake\Core\Configure;
use Cake\Cache\Cache;
use Cake\Core\Configure;
use Cake\Log\Log;
define('DS', DIRECTORY_SEPARATOR);
@@ -16,8 +16,8 @@
*/
namespace Cake\TestSuite\Fixture;
use Cake\TestSuite\TestCase;
use Cake\TestSuite\Fixture\FixtureManager;
use Cake\TestSuite\TestCase;
use \Exception;
use \PHPUnit_Framework_AssertionFailedError;
use \PHPUnit_Framework_Test;

0 comments on commit 50cff13

Please sign in to comment.