Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
archery
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
3
Issues
3
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Taddeüs Kroes
archery
Commits
f2de599f
Commit
f2de599f
authored
Oct 20, 2014
by
Taddeus Kroes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Registration page now redirects when logged in
parent
762e46ff
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
3 deletions
+2
-3
routes/common.php
routes/common.php
+1
-3
routes/register.php
routes/register.php
+1
-0
No files found.
routes/common.php
View file @
f2de599f
...
...
@@ -23,9 +23,7 @@ function login_form() {
}
$app
->
get
(
'/login'
,
function
()
use
(
$app
,
$user
)
{
if
(
$user
->
isLoggedIn
())
$app
->
redirect
(
ROOT_URL
);
$user
->
isLoggedIn
()
&&
$app
->
redirect
(
ROOT_URL
);
$app
->
render
(
'login'
,
array
(
'form'
=>
login_form
()));
});
...
...
routes/register.php
View file @
f2de599f
...
...
@@ -37,6 +37,7 @@ function registration_form() {
}
$app
->
get
(
'/register'
,
function
()
use
(
$app
,
$user
)
{
$user
->
isLoggedIn
()
&&
$app
->
redirect
(
ROOT_URL
);
$form
=
registration_form
();
$app
->
render
(
'register'
,
compact
(
'form'
));
});
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment