fleetbo-cockpit-cli 1.0.13 → 1.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cli.js +4 -1
- package/package.json +1 -1
package/cli.js
CHANGED
|
@@ -162,7 +162,10 @@ if (command === 'alex') {
|
|
|
162
162
|
const result = await axios.post(ALEX_ENGINE_URL, { prompt, projectType: 'android' }, {
|
|
163
163
|
headers: { 'x-project-id': projectId }
|
|
164
164
|
});
|
|
165
|
-
|
|
165
|
+
let aiData = result.data;
|
|
166
|
+
if (typeof aiData === 'string') {
|
|
167
|
+
try { aiData = JSON.parse(aiData); } catch (_) {}
|
|
168
|
+
}
|
|
166
169
|
process.stdout.write('\r' + ' '.repeat(50) + '\r');
|
|
167
170
|
|
|
168
171
|
if (aiData.status === 'quota_exceeded') {
|