lib/russian_phone/number.rb in russian_phone-0.3.1 vs lib/russian_phone/number.rb in russian_phone-0.3.2
- old
+ new
@@ -91,15 +91,19 @@
else
[]
end
end
+ def formatted_subscriber
+ format.join('-')
+ end
+
def full
if valid?
if free? && extra == ''
- "8-#{city}-#{format.join('-')}"
+ "8-#{city}-#{formatted_subscriber}"
else
- "+#{country} (#{city}) #{format.join('-')}#{extra == '' ? '' : ' ' + extra}"
+ "+#{country} (#{city}) #{formatted_subscriber}#{extra == '' ? '' : ' ' + extra}"
end
else
''
end
end
\ No newline at end of file