From 6c966f2afa504570e511ee327f6fff01577ef0fc Mon Sep 17 00:00:00 2001 From: jvoisin Date: Thu, 9 Jan 2025 01:21:31 +0100 Subject: Significantly improve portability --- libmat2/office.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libmat2/office.py') diff --git a/libmat2/office.py b/libmat2/office.py index d067128..1a793b4 100644 --- a/libmat2/office.py +++ b/libmat2/office.py @@ -525,7 +525,7 @@ class MSOfficeParser(ZipParser): # see: https://docs.microsoft.com/en-us/dotnet/framework/wpf/advanced/mc-ignorable-attribute with open(full_path, 'rb') as f: text = f.read() - out = re.sub(b'mc:Ignorable="[^"]*"', b'', text, 1) + out = re.sub(b'mc:Ignorable="[^"]*"', b'', text, count=1) with open(full_path, 'wb') as f: f.write(out) -- cgit v1.3