fix error caused by global find/replace command