Skip to content

Commit

Permalink
Fix Login class and semplify Autoloader
Browse files Browse the repository at this point in the history
Before fix, login data never retrieved
  • Loading branch information
s3b4stian committed Sep 2, 2016
1 parent 4c2a09b commit d6b72d2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
1 change: 1 addition & 0 deletions src/Linna/Auth/Login.php
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,7 @@ private function refresh()
}

$this->sessionInstance->loginTime = $time;
$this->data = $this->sessionInstance->login;

return true;
}
Expand Down
5 changes: 1 addition & 4 deletions src/Linna/Autoloader.php
Original file line number Diff line number Diff line change
Expand Up @@ -163,13 +163,10 @@ protected function loadMappedFile($prefix, $relativeClass)
// replace the namespace prefix with the base directory,
// replace namespace separators with directory separators
// in the relative class name, append with .php
$file = $baseDir
.str_replace('\\', '/', $relativeClass)
.'.php';
$file = $baseDir.str_replace('\\', '/', $relativeClass).'.php';

// if the mapped file exists, require it
if (file_exists($file)) {

require $file;

// yes, we're done
Expand Down

0 comments on commit d6b72d2

Please sign in to comment.