Skip to content

Commit

Permalink
Maintain PdfFileMerger strict default
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinThoma committed May 14, 2022
1 parent b993c8b commit ba6a427
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion PyPDF2/merger.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ class PdfMerger(object):
``True``).
"""

def __init__(self, strict=True, overwriteWarnings="deprecated"):
def __init__(self, strict=False, overwriteWarnings="deprecated"):
if overwriteWarnings != "deprecated":
warnings.warn(
"The `overwriteWarnings` argument to PdfReader will be removed with PyPDF2 2.0.0.",
Expand Down Expand Up @@ -676,4 +676,6 @@ def __init__(self, *args, **kwargs):
PendingDeprecationWarning,
stacklevel=2,
)
if "strict" not in kwargs and len(args) < 1:
kwargs["strict"] = True # maintain the default
super().__init__(*args, **kwargs)

0 comments on commit ba6a427

Please sign in to comment.