Skip to content

Commit

Permalink
Merge pull request #3 from CristianDRM/master
Browse files Browse the repository at this point in the history
feat: add method to formatt string
  • Loading branch information
CristianDRM committed Jun 26, 2017
2 parents e3d8c93 + 3ab0c36 commit 2a0208c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion GeneralFormatter.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

Pod::Spec.new do |s|
s.name = 'GeneralFormatter'
s.version = '2.0.0'
s.version = '2.0.1'
s.summary = 'A general formatter.'

# This description is used to generate tags and improve search results.
Expand Down
4 changes: 4 additions & 0 deletions GeneralFormatter/Classes/GeneralFormatter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ public enum GeneralFormatter {
}
}

public func format(value: String) -> String {
return formatter.format(value: value)
}

public func formatTextField(_ textField: UITextField, shouldChangeCharactersIn range: NSRange, replacementString string: String) -> Bool {
return formatter.shouldChangeCharacters(of: textField, inRange: range)
}
Expand Down

0 comments on commit 2a0208c

Please sign in to comment.