Skip to content

Conversation

@SoftCreatR
Copy link
Contributor

After saving, attachment BBCodes may be normalized from [attach=1612][/attach] to [attach='1612'][/attach] (or double-quoted), which caused inserted-attachment detection to fail on edit.

This change updates the BBCode matcher to capture numeric IDs regardless of optional single/double quotes around the ID, so previously inserted attachments are correctly recognized in all formats.

  • before: matched quoted IDs but parsed NaN
  • after: captures digits only and parses reliably

Capture only digits in group 1, so parseInt(match[1], 10) works for quoted and unquoted IDs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant