Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
Recca Tsai committed Jul 22, 2016
2 parents 2b160cb + 68fb76e commit c4fdc27
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 4 deletions.
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
"illuminate/filesystem": "~5.1",
"illuminate/routing": "~5.1",
"paragonie/random_compat": "~1.1",
"symfony/finder": "2.7.*|2.8.*|3.0.*"
"symfony/finder": "2.7.*|2.8.*|3.0.*",
"illuminate/encryption": "^5.2"
},
"require-dev": {
"nesbot/carbon": "~1.20",
Expand Down
2 changes: 1 addition & 1 deletion public/js/bundle.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions resources/assets/js/commands/help.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,6 @@ export default class Help extends Command {

call(cmd) {
this.api.echo(this.api.options.helpInfo);
this.api.serverInfo();
}
}
8 changes: 6 additions & 2 deletions src/Http/Controllers/TerminalController.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

namespace Recca0120\Terminal\Http\Controllers;

use Illuminate\Contracts\Encryption\Encrypter;
use Illuminate\Contracts\Foundation\Application as ApplicationContract;
use Illuminate\Filesystem\Filesystem;
use Illuminate\Http\Request;
Expand Down Expand Up @@ -36,15 +37,18 @@ public function __construct(ConsoleKernel $consoleKernel)
* @param \Illuminate\Contracts\Foundation\Application $app
* @param \Illuminate\Session\SessionManager $sessionManager
* @param \Illuminate\Http\Request $request
* @param \Illuminate\Contracts\Encryption\Encrypter $encrypter
* @param string $view
*
* @return mixed
*/
public function index(ApplicationContract $app, SessionManager $sessionManager, Request $request, $view = 'index')
public function index(ApplicationContract $app, SessionManager $sessionManager, Request $request, Encrypter $encrypter, $view = 'index')
{
$session = $sessionManager->driver();
if ($session->isStarted() === false) {
$session->setId($request->cookies->get($session->getName()));
$sessionName = $request->cookies->get($session->getName());
$sessionName = ($session->isValidId($sessionName) === false) ? $encrypter->decrypt($sessionName) : $sessionName;
$session->setId($sessionName);
$session->setRequestOnHandler($request);
$session->start();
}
Expand Down

0 comments on commit c4fdc27

Please sign in to comment.