##// END OF EJS Templates
ip-restritions: fix issue with loading empty IP rules for non-logged not-anonymous users....
marcink -
r2838:d1dcf373 default
parent child Browse files
Show More
@@ -1292,6 +1292,11 b' class AuthUser(object):'
1292 # we get deleted objects here, we just skip them
1292 # we get deleted objects here, we just skip them
1293 pass
1293 pass
1294
1294
1295 # NOTE:(marcink) we don't want to load any rules for empty
1296 # user_id which is the case of access of non logged users when anonymous
1297 # access is disabled
1298 user_ips = []
1299 if user_id:
1295 user_ips = UserIpMap.query().filter(UserIpMap.user_id == user_id)
1300 user_ips = UserIpMap.query().filter(UserIpMap.user_id == user_id)
1296 if cache:
1301 if cache:
1297 user_ips = user_ips.options(
1302 user_ips = user_ips.options(
General Comments 0
You need to be logged in to leave comments. Login now