Skip to content

Open-Source API Development Ecosystem • https://hoppscotch.io • Offline, On-Prem & Cloud • Web, Desktop & CLI • Open-Source Alternative to Postman, Insomnia

Clear history is now disabled when there aren't any histories

Igor Guastalla de Lima8226d0a1aedf
diff --git a/components/history.vue b/components/history.vue
index 79a489d7b..05d802e16 100644
--- a/components/history.vue
+++ b/components/history.vue
@@ -126,6 +126,7 @@
updateOnLocalStorage('history', this.history);
},
enableHistoryClearing() {
+ if (!this.history || !this.history.length) return;
this.isClearingHistory = true;
},
disableHistoryClearing() {