From 1ecf51c2ab949186977327d4550a65881fcce1b2 Mon Sep 17 00:00:00 2001 From: Colm Cahalane Date: Mon, 5 Sep 2016 03:26:13 +0100 Subject: [PATCH] "LOCATION" --- ical.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ical.go b/ical.go index 48040c9..023bfe3 100644 --- a/ical.go +++ b/ical.go @@ -126,6 +126,7 @@ type VEvent struct { SUMMARY string DESCRIPTION string TZID string + LOCATION string AllDay bool } @@ -174,6 +175,11 @@ func (e *VEvent) EncodeIcal(w io.Writer) error { return err } } + if e.LOCATION != "" { + if _, err := b.WriteString("LOCATION:" + e.LOCATION + "\r\n"); err != nil { + return err + } + } if _, err := b.WriteString("DTSTART;" + tzidTxt + "VALUE=" + timeStampType + ":" + e.DTSTART.Format(timeStampLayout) + "\r\n"); err != nil { return err }