mirror of
https://github.com/HamzaSha1/zod-backend.git
synced 2025-07-14 17:45:46 +00:00
change access token duration
This commit is contained in:
@ -174,7 +174,7 @@ class JuniorSerializer(serializers.ModelSerializer):
|
||||
|
||||
def get_user_type(self, obj):
|
||||
email_verified = UserEmailOtp.objects.filter(email=obj.auth.username).last()
|
||||
if email_verified and email_verified.user_type != None:
|
||||
if email_verified and email_verified.user_type is not None:
|
||||
return email_verified.user_type
|
||||
return '1'
|
||||
|
||||
|
@ -97,7 +97,7 @@ REST_FRAMEWORK = {
|
||||
'PAGE_SIZE': 5,
|
||||
}
|
||||
SIMPLE_JWT = {
|
||||
'ACCESS_TOKEN_LIFETIME': timedelta(minutes=50),
|
||||
'ACCESS_TOKEN_LIFETIME': timedelta(hours=23, minutes=59, seconds=59, microseconds=999999),
|
||||
'REFRESH_TOKEN_LIFETIME': timedelta(days=7),
|
||||
}
|
||||
# Database
|
||||
|
Reference in New Issue
Block a user