perf: 修复上次引起的小bug

pull/6253/head
ibuler 2021-06-09 15:46:32 +08:00 committed by 老广
parent de6908e5a6
commit 34b2a5fe0b
1 changed files with 1 additions and 1 deletions

View File

@ -220,7 +220,7 @@ class UserConnectionTokenViewSet(RootOrgViewMixin, SerializerMixin2, GenericView
raise serializers.ValidationError('Token not found')
user = get_object_or_404(User, id=value.get('user'))
if user.is_valid:
if not user.is_valid:
raise serializers.ValidationError("User not valid, disabled or expired")
system_user = get_object_or_404(SystemUser, id=value.get('system_user'))