# File lib/openid/filestore.rb, line 129 def getAssociation(server_url) filename = getAssociationFilename(server_url) begin assoc_file = File.open(filename, "r") rescue Errno::ENOENT return nil else begin assoc_s = assoc_file.read ensure assoc_file.close end begin association = OpenID::ConsumerAssociation.deserialize(assoc_s) rescue "VersionError" self.removeIfPresent(filename) return nil end # clean up expired associations if association.expiresIn == 0 self.removeIfPresent(filename) return nil else return association end end end