Created
February 18, 2019 06:23
-
-
Save iaindooley/81d6004b4bd174bfd6fa11e9a460be14 to your computer and use it in GitHub Desktop.
Add date from email
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function addDateFromEmail(notification) | |
{ | |
var card = new Notification(notification).createdCard(); | |
try | |
{ | |
var data = Trellinator.parseDate(card.name()); | |
card | |
.setDue(data.date) | |
.setName(data.comment); | |
} | |
catch(e) | |
{ | |
Trellinator.log("Not setting due date on "+card.link()+" because no date strings were found: "+e); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment