require 'sinatra' require 'sinatra/contrib' @@errors ||= {} if @@errors.empty? Dir.glob( File.dirname( __FILE__ ) + '/xpath/*' ).each do |path| @@errors[File.basename( path )] = IO.read( path ) end end def variations @@variations ||= %w('" ]]]]]]]]]