Merge pull request #20379 from calixteman/fix_after_20373

Fix stream use when getting the text (follow-up of #20373)
This commit is contained in:
Tim van der Meij 2025-10-19 13:04:13 +02:00 committed by GitHub
commit b87c999815
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -4284,7 +4284,7 @@ class PartialEvaluator {
hash.update(`${firstChar}-${lastChar}`); // Fixes issue10665_reduced.pdf
if (toUnicode instanceof BaseStream) {
const stream = toUnicode.str || toUnicode;
const stream = toUnicode.stream || toUnicode;
const uint8array = stream.buffer
? new Uint8Array(stream.buffer.buffer, 0, stream.bufferLength)
: new Uint8Array(