checkoff 0.45.0 → 0.45.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 00345dff0088d724665e5f195a171e2d623bc089dc556c1bcf35ce2928b80964
4
- data.tar.gz: f33a10dc0f469a746c42da0e95ba6144c04fd27f7516d9e7d34d5c1a340fa3db
3
+ metadata.gz: 166520f53086eea60a30deae24eacea2bff98b58cc63e1bc14397e016cfce5a3
4
+ data.tar.gz: 182f61588c6343c7b16100a56357909b5d1c532a2580040fdb50828dedeb4032
5
5
  SHA512:
6
- metadata.gz: c259d2f5629b727dd43f6d9d6617a114d8392ef083f3e9a747a2302b5afab9432be160e47e44a19c247fbf34cbc291a34f77c7fc073f84117532c279af406cc8
7
- data.tar.gz: f999870785ad58d1da096da1f0c96d0080f6430dd377ea9fba2c6d9c8983c32a79524f3175c42aa649fca670c1da00b007f333fed82fbcccf85fbcb4599eb7cc
6
+ metadata.gz: 00461660f5b2f2927d5c0bd89b34e12a1393ce105dcddf6782054ef655c3ba55654c0d5a818e35907dd46d457beac3a18b637bb2a5379ae78d30913fdd55944d
7
+ data.tar.gz: 8aa6bdc999894732e1e243cac1617b6b40b905b80562c5d8d57bbf2a988b4f1b66fc7848dbe4937dc01228c503a4e26661bc17a28c75c6effed5b10d9afd10db
data/Gemfile.lock CHANGED
@@ -12,7 +12,7 @@ GIT
12
12
  PATH
13
13
  remote: .
14
14
  specs:
15
- checkoff (0.45.0)
15
+ checkoff (0.45.1)
16
16
  activesupport
17
17
  asana (> 0.10.0)
18
18
  cache_method
@@ -349,7 +349,11 @@ module Checkoff
349
349
  def evaluate(task, custom_field_name, num_days)
350
350
  custom_field = pull_custom_field_by_name_or_raise(task, custom_field_name)
351
351
 
352
+ # @sg-ignore
353
+ # @type [String, nil]
352
354
  time_str = custom_field.fetch('display_value')
355
+ return false if time_str.nil?
356
+
353
357
  time = Time.parse(time_str)
354
358
  n_days_from_now = (Time.now + (num_days * 24 * 60 * 60))
355
359
  time < n_days_from_now
@@ -375,7 +379,11 @@ module Checkoff
375
379
  def evaluate(task, custom_field_name, num_days)
376
380
  custom_field = pull_custom_field_by_name_or_raise(task, custom_field_name)
377
381
 
382
+ # @sg-ignore
383
+ # @type [String, nil]
378
384
  time_str = custom_field.fetch('display_value')
385
+ return false if time_str.nil?
386
+
379
387
  time = Time.parse(time_str)
380
388
  n_days_from_now = (Time.now + (num_days * 24 * 60 * 60))
381
389
  time >= n_days_from_now
@@ -429,10 +437,9 @@ module Checkoff
429
437
  def evaluate(task_selector)
430
438
  return true if task_selector.empty?
431
439
 
432
- # @param evaluator_class [Class<FunctionEvaluator>]
440
+ # @param evaluator_class [Class<TaskSelectorClasses::FunctionEvaluator>]
433
441
  FUNCTION_EVALUTORS.each do |evaluator_class|
434
442
  # @sg-ignore
435
- # @type [FunctionEvaluator]
436
443
  evaluator = evaluator_class.new(task_selector: task_selector,
437
444
  tasks: tasks)
438
445
 
@@ -448,7 +455,7 @@ module Checkoff
448
455
 
449
456
  # @sg-ignore
450
457
  # @param task_selector [Array]
451
- # @param evaluator [FunctionEvaluator]
458
+ # @param evaluator [TaskSelectorClasses::FunctionEvaluator]
452
459
  # @return [Boolean, Object, nil]
453
460
  def try_this_evaluator(task_selector, evaluator)
454
461
  # if task_selector is an array
@@ -3,5 +3,5 @@
3
3
  # Command-line and gem client for Asana (unofficial)
4
4
  module Checkoff
5
5
  # Version of library
6
- VERSION = '0.45.0'
6
+ VERSION = '0.45.1'
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: checkoff
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.45.0
4
+ version: 0.45.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vince Broz