1
0
Fork 0
mirror of synced 2024-10-01 01:28:51 +13:00

Merge pull request #4710 from Budibase/fix/execute-query-action

Fix execute query action
This commit is contained in:
Andrew Kingston 2022-02-28 08:15:12 +00:00 committed by GitHub
commit 67f1560c2d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -127,12 +127,16 @@ const queryExecutionHandler = async action => {
// Trigger a notification and invalidate the datasource as long as this // Trigger a notification and invalidate the datasource as long as this
// was not a readable query // was not a readable query
if (!query.readable) { if (!query.readable) {
API.notifications.error.success("Query executed successfully") notificationStore.actions.success("Query executed successfully")
await dataSourceStore.actions.invalidateDataSource(query.datasourceId) await dataSourceStore.actions.invalidateDataSource(query.datasourceId)
} }
return { result } return { result }
} catch (error) { } catch (error) {
notificationStore.actions.error(
"An error occurred while executing the query"
)
// Abort next actions // Abort next actions
return false return false
} }