Skip to content

file.bookmarks.name isn't initialized before being assigned to pseud_h3_tag #9

@simone-cominato

Description

@simone-cominato

I've noticed in parser.py, at line 276 that the "file.bookmarks.name" variable is a void string while being assigned to pseud_h3_tag.
The code snippet is the following:

pseud_h3_tag = '<DT><H3>' + file.bookmarks.name + '</H3>'
file.bookmarks = folder_handler(body_start - 1, pseud_h3_tag, lines[body_start:body_end + 1])
file.bookmarks.name = root_name

The result is that "pseud_h3_tag" is <DT><H3></H3> when used in the subsequent function.

The fix could be the following:

file.bookmarks.name = root_name
pseud_h3_tag = '<DT><H3>' + file.bookmarks.name + '</H3>'
file.bookmarks = folder_handler(body_start - 1, pseud_h3_tag, lines[body_start:body_end + 1])

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions