diff --git a/examples/transfer/process-image.ts b/examples/transfer/process-image.ts index f82b058..ee1a0d1 100644 --- a/examples/transfer/process-image.ts +++ b/examples/transfer/process-image.ts @@ -2,9 +2,8 @@ import { mo } from '../../src/index.ts'; export const processImage = mo(import.meta, (pixels: Uint8Array): Uint8Array => { // Invert each pixel (simulate image processing) - const result = new Uint8Array(pixels.length); for (let i = 0; i < pixels.length; i++) { - result[i] = 255 - pixels[i]; + pixels[i] = 255 - pixels[i]; } - return result; + return pixels; });