lib/rallycat/update.rb in rallycat-0.3.0 vs lib/rallycat/update.rb in rallycat-0.3.1

- old
+ new

@@ -27,9 +27,15 @@ if display_name = attributes[:owner] login_name = find_user(display_name) attributes[:owner] = login_name end + # If the task is marked as 'Complete', we should remove the remaining + # hours. + if attributes[:state] == "Completed" + attributes[:to_do] = 0.0 + end + task.update(attributes) messages = [] if attributes[:state]