fedimbed: guh
This commit is contained in:
parent
f24e645c62
commit
c75a0b938f
1 changed files with 2 additions and 2 deletions
|
@ -21,6 +21,7 @@ const BSKY_POST_REGEX =
|
|||
/^\/profile\/(did:plc:[a-z0-9]+|(did:web:)?[a-z0-9][a-z0-9.-]+[a-z0-9]*)\/post\/([a-z0-9]+)\/?$/i;
|
||||
|
||||
const PATH_REGEX = {
|
||||
truthsocial: /^\/@(.+?)\/posts\/\d+\/?/i,
|
||||
mastodon: /^\/@(.+?)\/([a-z0-9]+?)\/?/i,
|
||||
mastodon2: /^\/(.+?)\/statuses\/([a-z0-9]+?)\/?/i,
|
||||
pleroma: /^\/objects\/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\/?/,
|
||||
|
@ -33,7 +34,6 @@ const PATH_REGEX = {
|
|||
//cohost: /^\/[A-Za-z0-9]+\/post\/\d+-[A-Za-z0-9-]+\/?/,
|
||||
bluesky: BSKY_POST_REGEX,
|
||||
twitter: /^\/([a-z0-9_]+)\/status\/(\d+)\/?/i,
|
||||
truthsocial: /^\/@(.+?)\/posts\/\d+\/?/i,
|
||||
};
|
||||
|
||||
const PLATFORM_COLORS = {
|
||||
|
@ -118,7 +118,7 @@ function firefoxUseragent() {
|
|||
const now = Math.floor(Date.now() / 1000);
|
||||
const version = Math.floor(124 + (now - 1710892800) / 2419200);
|
||||
|
||||
return `\`Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:${version}.0) Gecko/20100101 Firefox/${version}.0\``;
|
||||
return `Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:${version}.0) Gecko/20100101 Firefox/${version}.0`;
|
||||
}
|
||||
|
||||
async function resolvePlatform(url) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue