fix: build

Massimo Melina committed Dec 14, 2021 at 21:39 UTC 16edf43f3c1f2036058a027231e518674ee730fb
3 files changed +4 -5
frontend/src/misc.ts
-4
@@ -46,7 +46,3 @@ export function round(v: number, decimals: number = 0) {
46 export function prefix(pre:string, v:string|number, post:string='') {
47 return v ? pre+v+post : ''
48 }
49 -
50 -export function enforceFinal(sub:string, s:string) {
51 - return s.endsWith(sub) ? s : s+sub
52 -}
\ No newline at end of file
src/apis.ts
+1 -1
@@ -1,7 +1,7 @@
1 import glob from 'fast-glob'
2 import Koa from 'koa'
3 import { vfs } from './vfs'
4 -import { enforceFinal } from '../frontend/src/misc'
4 +import { enforceFinal } from './misc'
5 import { Stats } from 'fs'
6 import { stat } from 'fs/promises'
7 import _ from 'lodash'
src/misc.ts new
+3
@@ -0,0 +1,3 @@
1 +export function enforceFinal(sub:string, s:string) {
2 + return s.endsWith(sub) ? s : s+sub
3 +}
\ No newline at end of file