You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: yaml_parser.rb
    path of file: ./repos/bhf/lib/bhf/settings
    
    the code of the file until where you have to start completion: module Bhf::Settings

  class YAMLParser

   
    
    def get_settings_array(array, dir = nil)
      array.each_with_object({'pages' => []}) do |file_name, tmp_settings_hash|
        absolut_path = false
        file_path = if dir
          "#{dir}/#{file_name}"
        else
          if file_name[0,1] == '/'
            absolut_path = true
            file_name
          else
            "/#{file_name}"
          end
        end