projects
/
platal.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Do not give latitude and longitude as arguments as they are always the same.
[platal.git]
/
classes
/
xnetsession.php
diff --git
a/classes/xnetsession.php
b/classes/xnetsession.php
index
765ad5e
..
27ed4d8
100644
(file)
--- a/
classes/xnetsession.php
+++ b/
classes/xnetsession.php
@@
-35,11
+35,12
@@
class XnetSession extends XorgSession
}
if (!S::logged() && Post::has('auth_type') && Post::v('auth_type') == 'xnet' && !Post::has('wait')) {
}
if (!S::logged() && Post::has('auth_type') && Post::v('auth_type') == 'xnet' && !Post::has('wait')) {
+ $email = Post::v('username');
$type = XDB::fetchOneCell('SELECT type
FROM accounts
$type = XDB::fetchOneCell('SELECT type
FROM accounts
- WHERE
hruid
= {?}',
-
Post::v('username')
);
- if (
!is_null($type) && $type != 'xnet'
) {
+ WHERE
email
= {?}',
+
$email
);
+ if (
(!is_null($type) && $type != 'xnet') || !User::isForeignEmailAddress($email)
) {
Platal::page()->trigErrorRedirect('Ce formulaire d\'authentification est réservé aux extérieurs à la communauté polytechnicienne.', '');
}
Platal::page()->trigErrorRedirect('Ce formulaire d\'authentification est réservé aux extérieurs à la communauté polytechnicienne.', '');
}