From 573385a630ef01945329e3d54f140af50a81a14c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ivar=20Conradi=20=C3=98sthus?= Date: Thu, 9 Dec 2021 21:54:32 +0100 Subject: [PATCH] fix: drop client_metrics table --- .../20211209205201-drop-client-metrics.js | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 src/migrations/20211209205201-drop-client-metrics.js diff --git a/src/migrations/20211209205201-drop-client-metrics.js b/src/migrations/20211209205201-drop-client-metrics.js new file mode 100644 index 0000000000..1ff324d6eb --- /dev/null +++ b/src/migrations/20211209205201-drop-client-metrics.js @@ -0,0 +1,17 @@ +'use strict'; + +exports.up = function (db, callback) { + db.runSql('DROP TABLE client_metrics;', callback); +}; + +exports.down = function (db, callback) { + db.runSql( + ` +CREATE TABLE client_metrics ( + id serial primary key, + created_at timestamp default now(), + metrics json +);`, + callback, + ); +};