Skip to content

Commit dc98a79

Browse files
remeiobclozel
authored andcommitted
Remove the catch of NPE because this issue had resolved at Jetty 12.0.2.
Closes gh-34235 Signed-off-by: Mengqi Xu <[email protected]>
1 parent 4d0f172 commit dc98a79

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

spring-websocket/src/main/java/org/springframework/web/socket/adapter/jetty/JettyWebSocketSession.java

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -183,13 +183,7 @@ public void initializeNativeSession(Session session) {
183183
this.extensions = getExtensions(session);
184184

185185
if (this.user == null) {
186-
try {
187-
this.user = session.getUpgradeRequest().getUserPrincipal();
188-
}
189-
catch (NullPointerException ex) {
190-
// Necessary until https://github.com/eclipse/jetty.project/issues/10498 is resolved
191-
logger.error("Failure from UpgradeRequest while getting Principal", ex);
192-
}
186+
this.user = session.getUpgradeRequest().getUserPrincipal();
193187
}
194188
}
195189

0 commit comments

Comments
 (0)