aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2020-07-12 15:57:41 +0200
committerHugo Hörnquist <hugo@lysator.liu.se>2020-07-12 15:57:41 +0200
commit2c70049bd77945418878d685008c725e7ead31e1 (patch)
tree907c69ddd95cbd38fbb1914aa3126a489447154a
parentFixed display end time of short events. (diff)
downloadcalp-2c70049bd77945418878d685008c725e7ead31e1.tar.gz
calp-2c70049bd77945418878d685008c725e7ead31e1.tar.xz
Remove parents_until.
-rw-r--r--static/script.js10
1 files changed, 0 insertions, 10 deletions
diff --git a/static/script.js b/static/script.js
index 1679c74e..91913946 100644
--- a/static/script.js
+++ b/static/script.js
@@ -16,16 +16,6 @@ function date_to_percent (date) {
return (date.getHours() + (date.getMinutes() / 60)) * 100/24;
}
-function parents_until (element, obj) {
- if (element === null) {
- return null;
- } else if (element.id == obj.id || element.classList.contains(obj.class)) {
- return element;
- } else {
- return parents_until (element.parentElement, obj);
- }
-}
-
function decimal_time_to_date (time, date) {
let hour = Math.floor(time);
let minute = (time - hour) * 60;