Code clean up, add new YAML check