entp / multipass Goto Github PK
View Code? Open in Web Editor NEWBare bones implementation of encoding and decoding MultiPass values for SSO.
License: MIT License
Bare bones implementation of encoding and decoding MultiPass values for SSO.
License: MIT License
After intalling "entp-multipass" gem, it still doesn't work because it's missing the "ezcrypto" library. You should probably list "jamescook-ezcrypto" as gem dependency.
I did:
sudo gem install multipass
..
Successfully installed ezcrypto-0.7.2
Successfully installed multipass-1.2.3
..
If I try and call MultiPass from my Rails obj (identical to https://help.tenderapp.com/faqs/setup-installation/multipass), I get:
NameError: uninitialized constant User::MultiPass
Whaa?
Thanks!!
Matt
Can we release the latest HEAD a013c58 as a new version? Thanks
rubyrails:~ (ruby-1.9.2@rails3)$ gem install entp-multipass
Fetching: entp-multipass-1.1.3.gem (100%)
ERROR: While executing gem ... (TypeError)
can't dup NilClass
diff --git a/lib/multipass.rb b/lib/multipass.rb
index e17e4d3..9c4681b 100644
--- a/lib/multipass.rb
+++ b/lib/multipass.rb
@@ -85,7 +85,7 @@ class MultiPass
# Force everything coming out of json into a Time object if it isn't already
# with YAJL, it parses dates for us (ugh)
if options.has_key?(:expires) && options[:expires].is_a?(String)
- options[:expires] = Time.parse(options[:expires])
+ options[:expires] = options[:expires].empty?? Time.now.utc : Time.parse(options[:expires])
end
if options[:expires].nil? || Time.now.utc > options[:expires]
>> RUBY_DESCRIPTION
=> "ruby 1.8.7 (2012-02-08 patchlevel 358) [i686-darwin11.4.0]"
>> require 'time'
=> true
>> Time.parse('')
=> Wed Aug 01 14:55:17 -0700 2012
>> RUBY_DESCRIPTION
=> "ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-darwin11.4.0]"
>> require 'time'
=> true
>> Time.parse('')
ArgumentError: no time information in ""
from .rbenv/versions/1.9.3-p125/lib/ruby/1.9.1/time.rb:267:in `parse'
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.