Skip to content

Commit

Permalink
minor message improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
cebe committed Jul 29, 2014
1 parent 6d1dd1d commit a9aebfa
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
5 changes: 5 additions & 0 deletions build/controllers/MimeTypeController.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

use Yii;
use yii\console\Controller;
use yii\helpers\Console;
use yii\helpers\VarDumper;

/**
Expand All @@ -33,7 +34,10 @@ public function actionIndex($outFile = null)
if ($outFile === null) {
$outFile = Yii::getAlias('@yii/helpers/mimeTypes.php');
}
$this->stdout('downloading mime-type file from apache httpd repository...');
if ($content = file_get_contents('http://svn.apache.org/viewvc/httpd/httpd/trunk/docs/conf/mime.types?view=co')) {
$this->stdout("done.\n", Console::FG_GREEN);
$this->stdout("generating file $outFile...");
$mimeMap = [];
foreach(explode("\n", $content) as $line) {
$line = trim($line);
Expand Down Expand Up @@ -65,6 +69,7 @@ public function actionIndex($outFile = null)
EOD;
file_put_contents($outFile, $content);
$this->stdout("done.\n", Console::FG_GREEN);
} else {
$this->stderr("Failed to download mime.types file from apache SVN.\n");
}
Expand Down
3 changes: 1 addition & 2 deletions extensions/debug/Module.php
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,7 @@ protected function checkAccess()
return true;
}
}
Yii::warning('Access to debugger is denied due to IP address restriction. The requested IP is ' . $ip, __METHOD__);

Yii::warning('Access to debugger is denied due to IP address restriction. The requesting IP address is ' . $ip, __METHOD__);
return false;
}

Expand Down

0 comments on commit a9aebfa

Please sign in to comment.