JS script for fixing inline error