lib/anti_captcha/models/solution.rb in anti_captcha-2.0.0 vs lib/anti_captcha/models/solution.rb in anti_captcha-2.1.0

- old
+ new

@@ -1,5 +1,12 @@ module AntiCaptcha class Solution < AntiCaptcha::Model attr_accessor :api_response, :task_result + + def initialize(task_result = nil) + if task_result + @api_response = task_result.api_result + @task_result = task_result + end + end end end