Commit bece24d2 authored by comfyanonymous's avatar comfyanonymous
Browse files

Merge branch 'fix/pnginfo-import' of https://github.com/filipemeneses/ComfyUI

parents c982c937 e76890dc
...@@ -32,8 +32,9 @@ export function getPngMetadata(file) { ...@@ -32,8 +32,9 @@ export function getPngMetadata(file) {
} }
const keyword = String.fromCharCode(...pngData.slice(offset + 8, keyword_end)); const keyword = String.fromCharCode(...pngData.slice(offset + 8, keyword_end));
// Get the text // Get the text
const text = String.fromCharCode(...pngData.slice(keyword_end + 1, offset + 8 + length)); const contentArraySegment = pngData.slice(keyword_end + 1, offset + 8 + length);
txt_chunks[keyword] = text; const contentJson = Array.from(contentArraySegment).map(s=>String.fromCharCode(s)).join('')
txt_chunks[keyword] = contentJson;
} }
offset += 12 + length; offset += 12 + length;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment