Fix JSHint errors in existing js files