Fix double patching