Skip to content

Commit

Permalink
Update _writer.py
Browse files Browse the repository at this point in the history
/TYPE for a link should be "/Annot" not "/Annots"

This change makes add_uri work;  previously, it did not.
  • Loading branch information
pmiller66 committed Jan 12, 2024
1 parent fc893d5 commit 8e461c0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pypdf/_writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -1922,7 +1922,7 @@ def add_uri(
lnk = DictionaryObject()
lnk.update(
{
NameObject(AA.Type): NameObject(PG.ANNOTS),
NameObject(AA.Type): NameObject("/Annot"),
NameObject(AA.Subtype): NameObject("/Link"),
NameObject(AA.P): page_link,
NameObject(AA.Rect): rect,
Expand Down

0 comments on commit 8e461c0

Please sign in to comment.