mirror of
https://github.com/tenrok/BBob.git
synced 2026-05-15 11:59:37 +03:00
09ff9af9a2
* attrsToString: To avoid some malformed attributes
Error:
```
TypeError: Cannot convert undefined or null to object
at Function.keys (<anonymous>)
at attrsToString
```
This errors appears if no `attrs` setted in custom tag:
```
const BBcodePresetTemp = BbobPresetHTML5.extend((tags: any) => {
tags.br = () => ({
tag: 'br',
// attrs: {}, // <-- Comment this line for error and add [br] to text
content: null,
});
return tags;
});
```