rubycas / rubycas-client

Ruby client for Yale's Central Authentication Service protocol -- an open source enterprise single sign on system for web applications.
http://code.google.com/p/rubycas-client/
Other
332 stars 217 forks source link

Remove rails method 'blank?' #72

Closed KrauseFx closed 10 years ago

KrauseFx commented 10 years ago

I'm using rubycas-client without rails. The method 'blank?' is only available in the rails environment.

This pull request removes this requirement and allows us to use rubycas without adding the blank method to 'Object'.

soupmatt commented 10 years ago

We can remove usage of blank, but the implementation you provided will error when the values are nil. ActiveSupport's blank? will return true on nil.

KrauseFx commented 10 years ago

No, it's working, try the following code in the irb:

nil.to_s.empty?

soupmatt commented 10 years ago

I stand corrected. It works as you say.

KrauseFx commented 10 years ago

Awesome, thanks for merging :+1: