You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by Sam Ruby <ru...@apache.org> on 2016/03/13 22:45:28 UTC
[whimsy.git] [1/1] Commit 34334c4: flag missing attachments
Commit 34334c41663addc1b820b571cb5ccb836361c4f6:
flag missing attachments
Branch: refs/heads/master
Author: Sam Ruby <ru...@intertwingly.net>
Committer: Sam Ruby <ru...@intertwingly.net>
Pusher: rubys <ru...@apache.org>
------------------------------------------------------------
lib/whimsy/asf/agenda.rb | +++++++++
------------------------------------------------------------
9 changes: 9 additions, 0 deletions.
------------------------------------------------------------
diff --git a/lib/whimsy/asf/agenda.rb b/lib/whimsy/asf/agenda.rb
index 41f6439..0687841 100644
--- a/lib/whimsy/asf/agenda.rb
+++ b/lib/whimsy/asf/agenda.rb
@@ -124,6 +124,15 @@ def parse(file, quick=false)
hash[:attach] = section
end
+ # look for missing titles
+ @sections.each do |section, hash|
+ hash['title'] ||= "UNKNOWN"
+
+ if hash['title'] == "UNKNOWN"
+ hash['warnings'] = ['unable to find attachment']
+ end
+ end
+
@sections.values
end