fix and test email parsing, add mock matrix

This commit is contained in:
Bel LaPointe
2022-01-11 00:02:00 -05:00
parent ec2b514a9f
commit 392578bb54
6 changed files with 72 additions and 13 deletions

View File

@@ -16,6 +16,7 @@ type Config struct {
Client string
Message struct {
Matrix struct {
Mock bool
Homeserver string
Username string
Token string

View File

@@ -11,7 +11,7 @@ func (d Duration) Get() time.Duration {
return time.Duration(d)
}
func (d *Duration) MarshalJSON() ([]byte, error) {
func (d Duration) MarshalJSON() ([]byte, error) {
return json.Marshal(d.Get().String())
}