diff --git a/src/services/pythonCliAuth.ts b/src/services/pythonCliAuth.ts index 9bb8037..a296731 100644 --- a/src/services/pythonCliAuth.ts +++ b/src/services/pythonCliAuth.ts @@ -187,8 +187,14 @@ class PythonCliAuth { verbose: true } }); - - return response.success; + if (!response.success) { + throw new Error(response.error || response.message || 'Command execution failed'); + } + const data = response.data; + if (data && data.success) { + return data.success; + } + throw new Error(data?.message || 'Token verification failed'); } catch (error) { console.error('Token verification failed:', error); return false;