When "format_on_save" is enabled, first check if there are some lint errors and skip the formatting in that case