lib/github_bot/validator/base.rb
# Public: Loads the yaml of the file provided
#
# @param file [Sawyer::Resource] The file to load
Loads the yaml of the file provided
Loads the yaml of the file provided
def load_yaml(file)
        YAML.safe_load(client_api.file_content(file)).with_indifferent_access
      rescue StandardError => e
        feedback(
          path: file.filename,
          annotation_level: 'failure',
          message: 'Malformed yaml content'\
                   "exception: #{e.message}"
        )
        {}
      end
def load_yaml ( file ) YAML . safe_load ( client_api . file_content ( file ) ) . with_indifferent_access rescue StandardError => e feedback ( path : file . filename , annotation_level : 'failure' , message : 'Malformed yaml content' "exception: #{e.message}" ) { } end
Public: Loads the yaml of the file provided
Public : Loads the yaml of the file provided
file
The file to load
The file to load