From 52b79f4b5ffce7679fa5fcceeb80d615ad0cdf16 Mon Sep 17 00:00:00 2001 From: stonedDiscord Date: Fri, 11 Mar 2022 18:15:55 +0100 Subject: add apng preanims --- webAO/utils/getAnimLength.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'webAO/utils/getAnimLength.js') diff --git a/webAO/utils/getAnimLength.js b/webAO/utils/getAnimLength.js index 5b24e84..1441548 100644 --- a/webAO/utils/getAnimLength.js +++ b/webAO/utils/getAnimLength.js @@ -1,6 +1,6 @@ import calculatorHandler from './calculatorHandler'; import fileExists from './fileExists.js'; -import requestBuffer from '../services/request.js'; +import {requestBuffer} from '../services/request.js'; /** * Gets animation length. If the animation cannot be found, it will * silently fail and return 0 instead. @@ -8,7 +8,7 @@ import requestBuffer from '../services/request.js'; */ const getAnimLength = async (url) => { - const extensions = ['.gif', '.webp']; + const extensions = ['.gif', '.webp', '.apng']; for (const extension of extensions) { const urlWithExtension = url + extension; const exists = await fileExists(urlWithExtension); -- cgit