Skip to content

Instantly share code, notes, and snippets.

@no6v
Created May 23, 2012 03:14
Show Gist options
  • Save no6v/2773065 to your computer and use it in GitHub Desktop.
Save no6v/2773065 to your computer and use it in GitHub Desktop.
diff --git a/lib/earthquake/input.rb b/lib/earthquake/input.rb
index aaafee8..787a451 100644
--- a/lib/earthquake/input.rb
+++ b/lib/earthquake/input.rb
@@ -78,6 +78,7 @@ module Earthquake
else
raise "type must be :y or :n"
end
+ s = {"\cY" => "Y", "\cN" => "N"}[s]
s = type.to_s if s.empty?
if m = s.match(/^[yn]$/i)
return m[0].downcase == 'y'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment