Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
Antti Väyrynen
/
Moya
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 0cbebcb7
authored
Sep 15, 2012
by
Tuomas Riihimäki
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add case insensitive usenamecheck to user creation.
1 parent
25cc7ecc
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 additions
and
3 deletions
code/LanBortalBeans/ejbModule/fi/insomnia/bortal/facade/UserFacade.java
code/LanBortalBeansClient/ejbModule/fi/insomnia/bortal/clientutils/BortalLocalContextHolder.java
code/LanBortalBeans/ejbModule/fi/insomnia/bortal/facade/UserFacade.java
View file @
0cbebcb
...
@@ -80,7 +80,7 @@ public class UserFacade extends IntegerPkGenericFacade<User> {
...
@@ -80,7 +80,7 @@ public class UserFacade extends IntegerPkGenericFacade<User> {
CriteriaBuilder
cb
=
getEm
().
getCriteriaBuilder
();
CriteriaBuilder
cb
=
getEm
().
getCriteriaBuilder
();
CriteriaQuery
<
User
>
cq
=
cb
.
createQuery
(
User
.
class
);
CriteriaQuery
<
User
>
cq
=
cb
.
createQuery
(
User
.
class
);
Root
<
User
>
root
=
cq
.
from
(
User
.
class
);
Root
<
User
>
root
=
cq
.
from
(
User
.
class
);
cq
.
where
(
cb
.
equal
(
root
.
get
(
User_
.
login
),
login
));
cq
.
where
(
cb
.
equal
(
root
.
get
(
User_
.
login
),
login
.
toLowerCase
().
trim
()
));
return
getSingleNullableResult
(
getEm
().
createQuery
(
cq
));
return
getSingleNullableResult
(
getEm
().
createQuery
(
cq
));
}
}
...
...
code/LanBortalBeansClient/ejbModule/fi/insomnia/bortal/clientutils/BortalLocalContextHolder.java
View file @
0cbebcb
...
@@ -35,7 +35,6 @@ public class BortalLocalContextHolder {
...
@@ -35,7 +35,6 @@ public class BortalLocalContextHolder {
public
static
void
setHostname
(
String
hostname
)
{
public
static
void
setHostname
(
String
hostname
)
{
getThread
().
hostname
=
hostname
;
getThread
().
hostname
=
hostname
;
logger
.
info
(
"Setting hostname to {}"
,
hostname
);
}
}
...
@@ -107,7 +106,6 @@ public class BortalLocalContextHolder {
...
@@ -107,7 +106,6 @@ public class BortalLocalContextHolder {
}
}
public
static
void
copy
(
BortalLocalContextHolder
contextHolder
)
{
public
static
void
copy
(
BortalLocalContextHolder
contextHolder
)
{
logger
.
debug
(
"Copying context holder to new. Hostname {} "
,
contextHolder
.
getHolderHostname
());
if
(
THREAD_WITH_CONTEXT
.
get
()
!=
null
)
{
if
(
THREAD_WITH_CONTEXT
.
get
()
!=
null
)
{
logger
.
warn
(
"Context for thread is not empty. Received hostname {}"
,
THREAD_WITH_CONTEXT
.
get
().
hostname
);
logger
.
warn
(
"Context for thread is not empty. Received hostname {}"
,
THREAD_WITH_CONTEXT
.
get
().
hostname
);
}
}
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment