style: auto-fix ESLint issues (curly braces and formatting)
- Add curly braces to all if/else/for/while statements - Fix indentation and trailing spaces - Auto-fixed 372 linting errors using eslint --fix - Remaining issues are warnings only (non-null assertions, explicit any types)
This commit is contained in:
+2
-2
@@ -21,7 +21,7 @@ const NAMED_ENTITIES: Record<string, string> = {
|
||||
function decodeEntity(entity: string): string {
|
||||
// Named entity
|
||||
const named = NAMED_ENTITIES[entity.toLowerCase()];
|
||||
if (named) return named;
|
||||
if (named) {return named;}
|
||||
|
||||
// Decimal numeric entity: &#NNN;
|
||||
const decMatch = entity.match(/^&#(\d+);$/);
|
||||
@@ -52,7 +52,7 @@ function decodeEntity(entity: string): string {
|
||||
* @returns Clean plain text
|
||||
*/
|
||||
export function sanitizeHtml(text: string): string {
|
||||
if (!text) return '';
|
||||
if (!text) {return '';}
|
||||
|
||||
let result = text;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user