Skip to content
This repository was archived by the owner on Nov 9, 2017. It is now read-only.

Commit 613db20

Browse files
author
Aaron Kuzemchak
committed
Laravel upgrade
1 parent 927fc71 commit 613db20

19 files changed

+216
-36
lines changed

.gitignore

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22
.DS_Store
33

44
# Composer
5-
/vendor
5+
/vendor
6+
/bootstrap/compiled.php

app/config/app.php

+11-6
Original file line numberDiff line numberDiff line change
@@ -43,16 +43,16 @@
4343

4444
/*
4545
|--------------------------------------------------------------------------
46-
| Application Fallback Locale
46+
| Routable Locales
4747
|--------------------------------------------------------------------------
4848
|
49-
| The fallback locale determines the locale to use when the current one
50-
| is not available. You may change the value to correspond to any of
51-
| the language folders that are provided through your application.
49+
| Here you may list the locales that are "routable" for your application.
50+
| When a request with a URI beginning with one of the locales is sent
51+
| to the application, the "default" locale will be set accordingly.
5252
|
5353
*/
5454

55-
'fallback_locale' => 'en',
55+
'locales' => array(),
5656

5757
/*
5858
|--------------------------------------------------------------------------
@@ -92,15 +92,18 @@
9292
'Illuminate\Encryption\EncryptionServiceProvider',
9393
'Illuminate\Filesystem\FilesystemServiceProvider',
9494
'Illuminate\Hashing\HashServiceProvider',
95+
'Illuminate\Html\HtmlServiceProvider',
9596
'Illuminate\Foundation\Providers\KeyGeneratorServiceProvider',
9697
'Illuminate\Log\LogServiceProvider',
9798
'Illuminate\Mail\MailServiceProvider',
9899
'Illuminate\Database\MigrationServiceProvider',
100+
'Illuminate\Foundation\Providers\OptimizeServiceProvider',
99101
'Illuminate\Pagination\PaginationServiceProvider',
100102
'Illuminate\Foundation\Providers\PublisherServiceProvider',
101103
'Illuminate\Queue\QueueServiceProvider',
102104
'Illuminate\Redis\RedisServiceProvider',
103105
'Illuminate\Auth\Reminders\ReminderServiceProvider',
106+
'Illuminate\Foundation\Providers\RouteListServiceProvider',
104107
'Illuminate\Database\SeedServiceProvider',
105108
'Illuminate\Foundation\Providers\ServerServiceProvider',
106109
'Illuminate\Session\SessionServiceProvider',
@@ -123,7 +126,7 @@
123126
|
124127
*/
125128

126-
'manifest' => __DIR__.'/../storage/meta',
129+
'manifest' => storage_path().'/meta',
127130

128131
/*
129132
|--------------------------------------------------------------------------
@@ -152,7 +155,9 @@
152155
'Eloquent' => 'Illuminate\Database\Eloquent\Model',
153156
'Event' => 'Illuminate\Support\Facades\Event',
154157
'File' => 'Illuminate\Support\Facades\File',
158+
'Form' => 'Illuminate\Support\Facades\Form',
155159
'Hash' => 'Illuminate\Support\Facades\Hash',
160+
'Html' => 'Illuminate\Support\Facades\Html',
156161
'Input' => 'Illuminate\Support\Facades\Input',
157162
'Lang' => 'Illuminate\Support\Facades\Lang',
158163
'Log' => 'Illuminate\Support\Facades\Log',

app/config/cache.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
|
2929
*/
3030

31-
'path' => __DIR__.'/../storage/cache',
31+
'path' => storage_path().'/cache',
3232

3333
/*
3434
|--------------------------------------------------------------------------

app/config/compile.php

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<?php
2+
3+
return array(
4+
5+
/*
6+
|--------------------------------------------------------------------------
7+
| Additional Compiled Classes
8+
|--------------------------------------------------------------------------
9+
|
10+
| Here you may specify additional classes to include in the compiled file
11+
| generated by the `artisan optimize` command. These should be classes
12+
| that are included on basically every request into the application.
13+
|
14+
*/
15+
16+
17+
18+
);

app/config/database.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171
'password' => '',
7272
'charset' => 'utf8',
7373
'prefix' => '',
74-
'schema' => 'public',
74+
'schema' => 'public',
7575
),
7676

7777
'sqlsrv' => array(
@@ -119,4 +119,4 @@
119119

120120
),
121121

122-
);
122+
);

app/config/mail.php

+17-2
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,21 @@
22

33
return array(
44

5+
/*
6+
|--------------------------------------------------------------------------
7+
| Mail Driver
8+
|--------------------------------------------------------------------------
9+
|
10+
| Laravel supports both SMTP and PHP's "mail" function as drivers for the
11+
| sending of e-mail. You may specify which one you're using throughout
12+
| your application here. By default, Laravel is setup for SMTP mail.
13+
|
14+
| Supported: "smtp", "mail"
15+
|
16+
*/
17+
18+
'driver' => 'smtp',
19+
520
/*
621
|--------------------------------------------------------------------------
722
| SMTP Host Address
@@ -13,7 +28,7 @@
1328
|
1429
*/
1530

16-
'host' => 'smtp.postmarkapp.com',
31+
'host' => 'smtp.mailgun.org',
1732

1833
/*
1934
|--------------------------------------------------------------------------
@@ -26,7 +41,7 @@
2641
|
2742
*/
2843

29-
'port' => 2525,
44+
'port' => 587,
3045

3146
/*
3247
|--------------------------------------------------------------------------

app/config/queue.php

+10-3
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@
1111
| API, giving you convenient access to each back-end using the same
1212
| syntax for each one. Here you may set the default queue driver.
1313
|
14-
| Supported: "sync", "beanstalkd"
14+
| Supported: "sync", "beanstalkd", "sqs", "iron"
1515
|
1616
*/
1717

18-
'default' => 'sqs',
18+
'default' => 'sync',
1919

2020
/*
2121
|--------------------------------------------------------------------------
@@ -48,6 +48,13 @@
4848
'region' => 'us-east-1',
4949
),
5050

51+
'iron' => array(
52+
'driver' => 'iron',
53+
'project' => 'your-project-id',
54+
'token' => 'your-token',
55+
'queue' => 'your-queue-name',
56+
),
57+
5158
),
5259

53-
);
60+
);

app/config/session.php

+41-2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
| requests. By default we will use the light-weight cookie driver but
1212
| you may specify any of the other wonderful drivers provided here.
1313
|
14-
| Supported: "cookie", file", "database", "apc",
14+
| Supported: "cookie", "file", "database", "apc",
1515
| "memcached", "redis", "array"
1616
|
1717
*/
@@ -42,7 +42,7 @@
4242
|
4343
*/
4444

45-
'path' => __DIR__.'/../storage/sessions',
45+
'files' => storage_path().'/sessions',
4646

4747
/*
4848
|--------------------------------------------------------------------------
@@ -96,4 +96,43 @@
9696

9797
'cookie' => 'laravel_session',
9898

99+
/*
100+
|--------------------------------------------------------------------------
101+
| Session Cookie Path
102+
|--------------------------------------------------------------------------
103+
|
104+
| The session cookie path determines the path for which the cookie will
105+
| be regarded as available. Typically, this will be the root path of
106+
| your application but you are free to change this when necessary.
107+
|
108+
*/
109+
110+
'path' => '/',
111+
112+
/*
113+
|--------------------------------------------------------------------------
114+
| Session Cookie Domain
115+
|--------------------------------------------------------------------------
116+
|
117+
| Here you may change the domain of the cookie used to identify a session
118+
| in your application. This will determine which domains the cookie is
119+
| available to in your application. A sensible default has been set.
120+
|
121+
*/
122+
123+
'domain' => null,
124+
125+
/*
126+
|--------------------------------------------------------------------------
127+
| Session Payload Cookie Name
128+
|--------------------------------------------------------------------------
129+
|
130+
| When using the "cookie" session driver, you may configure the name of
131+
| the cookie used as the session "payload". This cookie actually has
132+
| the encrypted session data stored within it for the application.
133+
|
134+
*/
135+
136+
'payload' => 'laravel_payload',
137+
99138
);

app/config/workbench.php

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
<?php
2+
3+
return array(
4+
5+
/*
6+
|--------------------------------------------------------------------------
7+
| Workbench Author Name
8+
|--------------------------------------------------------------------------
9+
|
10+
| When you create new packages via the Artisan "workbench" command your
11+
| name is needed to generate the composer.json file for your package.
12+
| You may specify it now so it is used for all of your workbenches.
13+
|
14+
*/
15+
16+
'name' => '',
17+
18+
/*
19+
|--------------------------------------------------------------------------
20+
| Workbench Author E-Mail Address
21+
|--------------------------------------------------------------------------
22+
|
23+
| Like the option above, your e-mail address is used when generating new
24+
| workbench packages. The e-mail is placed in your composer.json file
25+
| automatically whwen the package is created by the workbench tool.
26+
|
27+
*/
28+
29+
'email' => '',
30+
31+
);

app/filters.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757

5858
Route::filter('csrf', function()
5959
{
60-
if (Session::getToken() != Input::get('csrf_token'))
60+
if (Session::getToken() != Input::get('_token'))
6161
{
6262
throw new Illuminate\Session\TokenMismatchException;
6363
}
@@ -104,4 +104,4 @@
104104
{
105105
App::abort(403, 'Hourly request limit exceeded');
106106
}
107-
});
107+
});

app/start/global.php

+3-2
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313

1414
ClassLoader::addDirectories(array(
1515

16+
app_path().'/commands',
1617
app_path().'/controllers',
1718
app_path().'/models',
1819
app_path().'/database/seeds',
@@ -32,7 +33,7 @@
3233

3334
$logFile = 'log-'.php_sapi_name().'.txt';
3435

35-
Log::useDailyFiles(__DIR__.'/../storage/logs/'.$logFile);
36+
Log::useDailyFiles(storage_path().'/logs/'.$logFile);
3637

3738
/*
3839
|--------------------------------------------------------------------------
@@ -69,4 +70,4 @@
6970
|
7071
*/
7172

72-
require __DIR__.'/../events.php';
73+
require __DIR__.'/../events.php';

app/tests/TestCase.php

+11-11
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,18 @@
22

33
class TestCase extends Illuminate\Foundation\Testing\TestCase {
44

5-
/**
6-
* Creates the application.
7-
*
8-
* @return Symfony\Component\HttpKernel\HttpKernelInterface
9-
*/
10-
public function createApplication()
11-
{
12-
$unitTesting = true;
5+
/**
6+
* Creates the application.
7+
*
8+
* @return Symfony\Component\HttpKernel\HttpKernelInterface
9+
*/
10+
public function createApplication()
11+
{
12+
$unitTesting = true;
1313

14-
$testEnvironment = 'testing';
14+
$testEnvironment = 'testing';
1515

16-
return require __DIR__.'/../../bootstrap/start.php';
17-
}
16+
return require __DIR__.'/../../bootstrap/start.php';
17+
}
1818

1919
}

artisan

+16-1
Original file line numberDiff line numberDiff line change
@@ -56,4 +56,19 @@ $artisan = Illuminate\Console\Application::start($app);
5656
|
5757
*/
5858

59-
$artisan->run();
59+
$status = $artisan->run();
60+
61+
/*
62+
|--------------------------------------------------------------------------
63+
| Shutdown The Application
64+
|--------------------------------------------------------------------------
65+
|
66+
| Once Artisan has finished running. We will fire off the shutdown events
67+
| so that any final work may be done by the application before we shut
68+
| down the process. This is the last thing to happen to the request.
69+
|
70+
*/
71+
72+
$app->shutdown();
73+
74+
exit($status);

0 commit comments

Comments
 (0)