From 44e8c1e1c9124b36a78f775b9a7dd12152a71d98 Mon Sep 17 00:00:00 2001 From: rstular Date: Sun, 17 May 2020 14:15:35 +0200 Subject: GSEC bug fix - regex matching --- assets/js/gsec.js | 3 ++- dist/js/gsec.js | 3 ++- dist/pages/about.html | 2 +- dist/sw.js | 4 ++-- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/assets/js/gsec.js b/assets/js/gsec.js index 6c3de0f..d0e5fbb 100644 --- a/assets/js/gsec.js +++ b/assets/js/gsec.js @@ -314,7 +314,8 @@ class gsec { for (const subjectString of subjectStrings) { var subjectName = SUBJECT_REGEX.exec(stripHtml(subjectString))[1]; - var abkurzung = ABKURZUNG_REGEX.exec(stripHtml(subjectString))[1]; + var abkurzung = ABKURZUNG_REGEX.exec(stripHtml(subjectString)); + abkurzung = abkurzung == null ? subjectName : abkurzung[1]; subjects[abkurzung] = subjectName; } diff --git a/dist/js/gsec.js b/dist/js/gsec.js index 6c3de0f..d0e5fbb 100644 --- a/dist/js/gsec.js +++ b/dist/js/gsec.js @@ -314,7 +314,8 @@ class gsec { for (const subjectString of subjectStrings) { var subjectName = SUBJECT_REGEX.exec(stripHtml(subjectString))[1]; - var abkurzung = ABKURZUNG_REGEX.exec(stripHtml(subjectString))[1]; + var abkurzung = ABKURZUNG_REGEX.exec(stripHtml(subjectString)); + abkurzung = abkurzung == null ? subjectName : abkurzung[1]; subjects[abkurzung] = subjectName; } diff --git a/dist/pages/about.html b/dist/pages/about.html index be31e44..8feacd2 100644 --- a/dist/pages/about.html +++ b/dist/pages/about.html @@ -142,7 +142,7 @@

- ^HEAD 96dd81ddf1188377bf1402e866c4b263dbd55d1c + ^HEAD ad64f108d5480155fad1424e9ea958f0c2227d60

diff --git a/dist/sw.js b/dist/sw.js index c2a150b..95cefde 100644 --- a/dist/sw.js +++ b/dist/sw.js @@ -3,8 +3,8 @@ // Change version to cause cache refresh -const static_cache_name = "site-static-1.0.13-beta-96dd81d"; -// latest commit is 96dd81ddf1188377bf1402e866c4b263dbd55d1c +const static_cache_name = "site-static-1.0.13-beta-ad64f10"; +// latest commit is ad64f108d5480155fad1424e9ea958f0c2227d60 // Got them with find . -not -path '*/\.*' | sed "s/.*/\"&\",/" | grep -v sw.js // sw.js NE SME BITI CACHAN, ker vsebuje verzijo! -- cgit v1.2.3