@geniehr/utilities 1.0.17 → 1.0.18
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.
|
@@ -161,13 +161,16 @@ export class ConductorClient {
|
|
|
161
161
|
return response.data.status;
|
|
162
162
|
}
|
|
163
163
|
catch (error) {
|
|
164
|
-
// Fallback to full workflow fetch
|
|
165
|
-
|
|
164
|
+
// Fallback to full workflow fetch if status endpoint doesn't exist or fails
|
|
165
|
+
// This handles 404, 405, or any other error from the status endpoint
|
|
166
|
+
try {
|
|
166
167
|
const workflow = await this.getWorkflow(workflowInstanceId, false);
|
|
167
168
|
return workflow.status;
|
|
168
169
|
}
|
|
169
|
-
|
|
170
|
-
|
|
170
|
+
catch (fallbackError) {
|
|
171
|
+
console.error(`Error getting workflow status:`, fallbackError.message);
|
|
172
|
+
throw fallbackError;
|
|
173
|
+
}
|
|
171
174
|
}
|
|
172
175
|
}
|
|
173
176
|
}
|