diff options
| author | Zack Hobson | 2009-08-09 10:59:49 -0700 | 
|---|---|---|
| committer | Zack Hobson | 2009-08-09 10:59:49 -0700 | 
| commit | b0738c3c74ccfba4af0258d4f26370564127cfdc (patch) | |
| tree | 60cc678d427ec853236ed3c6ab547bf77f525fd7 /lib | |
| parent | e935571b7164d112a5e27589ff69cfec9cc13c24 (diff) | |
| download | hcl-b0738c3c74ccfba4af0258d4f26370564127cfdc.tar.bz2 | |
Permit append to empty notes, closes #26.
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/hcl/day_entry.rb | 7 | 
1 files changed, 6 insertions, 1 deletions
| diff --git a/lib/hcl/day_entry.rb b/lib/hcl/day_entry.rb index bfc6dbf..db72748 100644 --- a/lib/hcl/day_entry.rb +++ b/lib/hcl/day_entry.rb @@ -27,9 +27,14 @@ module HCl      def append_note new_notes        # If I don't include hours it gets reset.        # This doens't appear to be the case for task and project. +      if notes.nil? +        notes = new_notes +      else +        notes << " #{new_notes}" +      end        DayEntry.post("daily/update/#{id}", <<-EOD)        <request> -        <notes>#{notes << " #{new_notes}"}</notes> +        <notes>#{notes}</notes>          <hours>#{hours}</hours>        </request>        EOD | 
