Fixing OPS_WRITE problem with a global argument