From 562236085b79b3fe793d9f02fdcbba9480c6a5ee Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Sat, 18 Dec 2021 16:03:15 +0300 Subject: style: format all Go code The code in //users/wpcarro/tools/monzo_ynab/ynab/client.go was not valid Go and has been commented out. Change-Id: Icb4003607f30294dcbf60132eb7722702c7f0d84 Reviewed-on: https://cl.tvl.fyi/c/depot/+/4400 Tested-by: BuildkiteCI Reviewed-by: wpcarro Reviewed-by: Profpatsch --- users/wpcarro/tools/monzo_ynab/main.go | 10 ++++---- users/wpcarro/tools/monzo_ynab/ynab/client.go | 36 +++++++++++++-------------- 2 files changed, 23 insertions(+), 23 deletions(-) (limited to 'users/wpcarro/tools') diff --git a/users/wpcarro/tools/monzo_ynab/main.go b/users/wpcarro/tools/monzo_ynab/main.go index f40c70ce27..bf37071381 100644 --- a/users/wpcarro/tools/monzo_ynab/main.go +++ b/users/wpcarro/tools/monzo_ynab/main.go @@ -10,8 +10,8 @@ package main import ( - "os" "monzoSerde" + "os" ) var ( @@ -25,10 +25,10 @@ var ( // Convert a Monzo transaction struct, `tx`, into a YNAB transaction struct. func toYnab(tx monzoSerde.Transaction) ynabSerde.Transaction { return ynabSerde.Transaction{ - Id: tx.Id, - Date: tx.Created, - Amount: tx.Amount, - Memo: tx.Notes, + Id: tx.Id, + Date: tx.Created, + Amount: tx.Amount, + Memo: tx.Notes, AccountId: ynabAccountID, } } diff --git a/users/wpcarro/tools/monzo_ynab/ynab/client.go b/users/wpcarro/tools/monzo_ynab/ynab/client.go index 0492b9071a..b3e9930f62 100644 --- a/users/wpcarro/tools/monzo_ynab/ynab/client.go +++ b/users/wpcarro/tools/monzo_ynab/ynab/client.go @@ -4,21 +4,21 @@ import ( "serde" ) -// See requests.txt for more details. -func PostTransactions(accountID string, txs []serde.Transaction{}) error { - return map[string]string{ - "transactions": [ - { - "account_id": accountID, - "date": "2019-12-30", - "amount": 10000, - "payee_name": "Richard Stallman", - "memo": "Not so free software after all...", - "cleared": "cleared", - "approved": true, - "flag_color": "red", - "import_id": "xyz-123" - } - ] - } -} +// // See requests.txt for more details. +// func PostTransactions(accountID string, txs []serde.Transaction{}) error { +// return map[string]string{ +// "transactions": [ +// { +// "account_id": accountID, +// "date": "2019-12-30", +// "amount": 10000, +// "payee_name": "Richard Stallman", +// "memo": "Not so free software after all...", +// "cleared": "cleared", +// "approved": true, +// "flag_color": "red", +// "import_id": "xyz-123" +// } +// ] +// } +// } -- cgit 1.4.1