Skip to content

Commit

Permalink
Merge pull request #7 from subfission/develop
Browse files Browse the repository at this point in the history
Reverted the AuthManager class for compatibility
  • Loading branch information
subfission committed May 20, 2015
2 parents 989fe17 + a5829dd commit 7e49b81
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 10 deletions.
9 changes: 4 additions & 5 deletions src/Subfission/Cas/CasManager.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php namespace Subfission\Cas;

use Illuminate\Contracts\Auth\Guard;
use Illuminate\Auth\AuthManager;

class CasManager {

Expand All @@ -12,18 +12,17 @@ class CasManager {
*/
protected $connections;
/**
* @var \Illuminate\Contracts\Auth\Guard
* @var \Illuminate\Auth\AuthManager
*/
private $auth;

/**
* @param array $config
* @param Guard $auth
*/
public function __construct(Guard $auth)
public function __construct()
{
$this->config = config('cas');
$this->auth = $auth;
$this->auth = app('auth');
}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/Subfission/Cas/CasServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function register()
{
$this->app->bindShared('cas', function()
{
return new CasManager(app('auth'));
return new CasManager();
});
}
/**
Expand Down
4 changes: 2 additions & 2 deletions src/Subfission/Cas/Middleware/CASAuth.php
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<?php namespace Subfission\Cas\Middleware;

use Closure;
use Illuminate\Contracts\Auth\Guard;
use Illuminate\Auth\AuthManager;

class CASAuth {

protected $config;
protected $auth;
protected $session;

public function __construct(Guard $auth)
public function __construct(Auth $auth)
{
$this->auth = $auth;
$this->config = config('cas');
Expand Down
4 changes: 2 additions & 2 deletions src/Subfission/Cas/Sso.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php namespace Subfission\Cas;

use Illuminate\Contracts\Auth\Guard;
use Illuminate\Auth\AuthManager;
use Illuminate\Support\Facades\Session;
use phpCAS;

Expand Down Expand Up @@ -34,7 +34,7 @@ class Sso {
* @param $config
* @param Auth $auth
*/
public function __construct($config, Guard $auth)
public function __construct($config, AuthManager $auth)
{
$this->config = $config;
$this->auth = $auth;
Expand Down

0 comments on commit 7e49b81

Please sign in to comment.