Compliance with PSR-0, PSR-1 and PSR-2

This commit is contained in:
Klaus Silveira
2012-07-14 15:47:46 -03:00
parent 6d11bed860
commit b00f723ac2
20 changed files with 129 additions and 117 deletions

View File

@@ -1,6 +1,6 @@
<?php
$app->get('{repo}/commits/{branch}/{file}', function($repo, $branch, $file) use($app) {
$app->get('{repo}/commits/{branch}/{file}', function($repo, $branch, $file) use ($app) {
$repository = $app['git']->getRepository($app['git.repos'] . $repo);
$type = $file ? "$branch -- $file" : $branch;
$pager = $app['utils']->getPager($app['request']->get('page'), $repository->getTotalCommits($type));
@@ -28,7 +28,7 @@ $app->get('{repo}/commits/{branch}/{file}', function($repo, $branch, $file) use(
->value('file', '')
->bind('commits');
$app->get('{repo}/commit/{commit}/', function($repo, $commit) use($app) {
$app->get('{repo}/commit/{commit}/', function($repo, $commit) use ($app) {
$repository = $app['git']->getRepository($app['git.repos'] . $repo);
$commit = $repository->getCommit($commit);
@@ -41,7 +41,7 @@ $app->get('{repo}/commit/{commit}/', function($repo, $commit) use($app) {
->assert('commit', '[a-f0-9]+')
->bind('commit');
$app->get('{repo}/blame/{branch}/{file}', function($repo, $branch, $file) use($app) {
$app->get('{repo}/blame/{branch}/{file}', function($repo, $branch, $file) use ($app) {
$repository = $app['git']->getRepository($app['git.repos'] . $repo);
$blames = $repository->getBlame("$branch -- $file");