瀏覽代碼

Add error id for expired auth tokens

KernelDeimos 1 年之前
父節點
當前提交
c70e378973
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      packages/backend/src/api/APIError.js

+ 4 - 0
packages/backend/src/api/APIError.js

@@ -319,6 +319,10 @@ module.exports = class APIError {
             status: 401,
             message: 'This authentication token is not supported here.',
         },
+        'token_expired': {
+            status: 401,
+            message: 'Authentication token has expired.',
+        },
         'account_suspended': {
             status: 403,
             message: 'Account suspended.',