mirror of
https://codeberg.org/uzu/strudel
synced 2026-07-13 06:19:33 -04:00
fallback
This commit is contained in:
@@ -1,6 +1,10 @@
|
||||
const ALLOW_MANY = ['by', 'url', 'genre', 'license'];
|
||||
|
||||
export function getMetadata(raw_code) {
|
||||
if (raw_code == null) {
|
||||
console.error('saved pattern is empty or corrupted')
|
||||
raw_code = '';
|
||||
}
|
||||
const comment_regexp = /\/\*([\s\S]*?)\*\/|\/\/(.*)$/gm;
|
||||
const comments = [...raw_code.matchAll(comment_regexp)].map((c) => (c[1] || c[2] || '').trim());
|
||||
const tags = {};
|
||||
|
||||
Reference in New Issue
Block a user