Permalink
Browse files

Added attribute readers for Flow's properties

  • Loading branch information...
1 parent 53b4376 commit 856458c1b29723ade26391b85b4062ac00be2c24 Antti Pitkanen committed Jun 20, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 lib/flowdock.rb
View
4 lib/flowdock.rb
@@ -10,7 +10,9 @@ class Flow
class InvalidParameterError < StandardError; end
class ApiError < StandardError; end
- # Required options keys: :api_token, optional keys: :external_user_name, :source, :from => { :name, :address }
+ attr_reader :api_token, :source, :project, :from, :external_user_name
+
+ # Required options keys: :api_token, optional keys: :external_user_name, :source, :project, :from => { :name, :address }
def initialize(options = {})
@api_token = options[:api_token]
raise InvalidParameterError, "Flow must have :api_token attribute" if blank?(@api_token)

0 comments on commit 856458c

Please sign in to comment.