fix(status): fix import status message (#4325)

Co-authored-by: Dmitry Mukovkin <d.mukovkin@cft.ru>
This commit is contained in:
Dmitry
2024-09-11 14:35:05 +07:00
committed by GitHub
parent 53839e1091
commit 35cc8c247d
3 changed files with 13 additions and 11 deletions

View File

@@ -401,15 +401,17 @@ const HoppMyCollectionsExporter: ImporterOrExporter = {
"hoppscotch-personal-collections"
)
E.isRight(message)
? toast.success(t(message.right))
: toast.error(t(message.left))
if (E.isRight(message)) {
toast.success(t("state.download_started"))
platform.analytics?.logEvent({
type: "HOPP_EXPORT_COLLECTION",
exporter: "json",
platform: "rest",
})
platform.analytics?.logEvent({
type: "HOPP_EXPORT_COLLECTION",
exporter: "json",
platform: "rest",
})
} else {
toast.error(t(message.left))
}
isHoppMyCollectionExporterInProgress.value = false
},

View File

@@ -148,7 +148,7 @@ const GqlCollectionsHoppExporter: ImporterOrExporter = {
return
}
toast.success(message.right)
toast.success(t("state.download_started"))
platform.analytics?.logEvent({
type: "HOPP_EXPORT_COLLECTION",

View File

@@ -239,11 +239,11 @@ const HoppEnvironmentsExport: ImporterOrExporter = {
)
if (E.isLeft(message)) {
toast.error(t(message.left))
toast.error(t("export.failed"))
return
}
toast.success(t(message.right))
toast.success(t("state.download_started"))
platform.analytics?.logEvent({
type: "HOPP_EXPORT_ENVIRONMENT",