Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion platform/CTFd/auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from flask import redirect, render_template, request, session, url_for
from flask_babel import lazy_gettext as _l

from CTFd.cache import clear_team_session, clear_user_session
from CTFd.cache import clear_team_session, clear_user_session, cache
from CTFd.exceptions.email import (
UserConfirmTokenInvalidException,
UserResetPasswordTokenInvalidException,
Expand Down
14 changes: 14 additions & 0 deletions platform/CTFd/themes/ddps/assets/js/index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import CTFd from "@ctfdio/ctfd-js";
import { Modal } from "bootstrap";

import dayjs from "dayjs";
import advancedFormat from "dayjs/plugin/advancedFormat";
Expand All @@ -20,6 +21,19 @@ import "./components/language";
dayjs.extend(advancedFormat);
CTFd.init(window.init);

const originalFetch = CTFd.fetch;
CTFd.fetch = async (url, options) => {
const response = await originalFetch(url, options);
if (response.status === 401) {
const modalElement = document.getElementById("session-expired-modal");
if (modalElement) {
const modal = new Modal(modalElement);
modal.show();
}
}
return response;
};

(() => {
styles();
times();
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

56 changes: 56 additions & 0 deletions platform/CTFd/themes/ddps/static/assets/echarts.128204f2.js

Large diffs are not rendered by default.

56 changes: 0 additions & 56 deletions platform/CTFd/themes/ddps/static/assets/echarts.7a5d4174.js

This file was deleted.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

31 changes: 31 additions & 0 deletions platform/CTFd/themes/ddps/static/assets/index.2cecd86f.js

Large diffs are not rendered by default.

31 changes: 0 additions & 31 deletions platform/CTFd/themes/ddps/static/assets/index.991665ba.js

This file was deleted.

9 changes: 0 additions & 9 deletions platform/CTFd/themes/ddps/static/assets/main.4d6b1408.css

This file was deleted.

9 changes: 9 additions & 0 deletions platform/CTFd/themes/ddps/static/assets/main.e9ec7884.css

Large diffs are not rendered by default.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion platform/CTFd/themes/ddps/static/assets/page.282159b3.js

This file was deleted.

1 change: 1 addition & 0 deletions platform/CTFd/themes/ddps/static/assets/page.aa03b084.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
import{C as o,m as d}from"./index.2cecd86f.js";window.CTFd=o;window.Alpine=d;d.start();

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading