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
4 changes: 2 additions & 2 deletions src/lib/utils/unique-identifier.js
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,8 @@ export function extractIdentifierFromUrl(url) {
return null;
}

// Match pattern /id/QCXXXXXXXX
const match = url.match(/\/id\/([A-Z0-9]{10})$/i);
// Match pattern /id/qryptchatXXXXXXXX (qryptchat prefix + 8 alphanumeric chars)
const match = url.match(/\/id\/(qryptchat[A-Z0-9]{8})$/i);
if (!match) {
return null;
}
Expand Down
4 changes: 2 additions & 2 deletions src/lib/utils/url-link-converter.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export function convertUrlsToLinks(text) {

// Extract code blocks and replace with placeholders
while ((codeMatch = codeBlockRegex.exec(text)) !== null) {
const placeholder = `__CODE_BLOCK_${codeIndex}__`;
const placeholder = `<[CODE_BLOCK_${codeIndex}]>`;
const codeContent = codeMatch[1];
codeBlocks.push(`<pre><code>${escapeHtml(codeContent)}</code></pre>`);
textWithPlaceholders = textWithPlaceholders.replace(codeMatch[0], placeholder);
Expand Down Expand Up @@ -87,7 +87,7 @@ export function convertUrlsToLinks(text) {

// Restore code blocks from placeholders
codeBlocks.forEach((codeBlock, index) => {
const placeholder = `__CODE_BLOCK_${index}__`;
const placeholder = `<[CODE_BLOCK_${index}]>`;
result = result.replace(placeholder, codeBlock);
});

Expand Down
Loading