Class: BillHicks::User
Instance Method Summary collapse
- #authenticated? ⇒ Boolean
-
#initialize(options = {}) ⇒ User
constructor
A new instance of User.
Methods inherited from Base
Constructor Details
#initialize(options = {}) ⇒ User
Returns a new instance of User.
4 5 6 7 |
# File 'lib/bill_hicks/user.rb', line 4 def initialize( = {}) requires!(, :username, :password) = end |
Instance Method Details
#authenticated? ⇒ Boolean
9 10 11 12 13 14 |
# File 'lib/bill_hicks/user.rb', line 9 def authenticated? connect() { |ftp| ftp.pwd } true rescue BillHicks::NotAuthenticated false end |