skip login in dev env, set ports tab on device links

This commit is contained in:
Oliver Gorwits
2012-01-09 11:13:43 +00:00
parent 9e9d408857
commit 8838215a50
6 changed files with 18 additions and 14 deletions

View File

@@ -13,9 +13,13 @@ use List::MoreUtils ();
hook 'before' => sub {
if (! session('user') && request->path !~ m{^/login}) {
session(user => 'oliver'); # XXX
#var(requested_path => request->path);
#request->path_info('/');
if (setting('environment') eq 'development') {
session(user => 'developer');
}
else {
var(requested_path => request->path);
request->path_info('/');
}
}
# make hash lookups of query lists