lib/codex_vitae.rb in codex_vitae-0.4.0 vs lib/codex_vitae.rb in codex_vitae-0.5.0
- old
+ new
@@ -1,8 +1,6 @@
def encrypt(codex)
-codex = self.to_s.downcase
-
transformer = {
"a" => "2",
"b" => "i",
"c" => "b",
"d" => "z",
@@ -36,8 +34,8 @@
"\"" => "t",
":" => "o",
"$" => "s",
"\'" => "j",
}
- encryption = codex.gsub(/\S/, transformer).gsub(/\s/, "4")
+ encryption = codex.to_s.downcase.gsub(/\S/, transformer).gsub(/\s/, "4")
puts encryption.upcase.chars.join(" ")
end