donate

donate - support content and projects from markhuge.com
Log | Files | Refs | README | LICENSE

commit 4cff375d02a732b36291013385ac9acefa8b488c
parent 3f13709e2745daa146475f0b16429c226f4c766f
Author: Mark Wilkerson <mark@markhuge.com>
Date:   Fri,  8 Oct 2021 18:43:53 -0700

make this a little less sloppy to use

Diffstat:
Mdonate.go | 37+++++++++++++++++++++++++++++++------
1 file changed, 31 insertions(+), 6 deletions(-)

diff --git a/donate.go b/donate.go @@ -17,7 +17,9 @@ package donate const ( - XMRQR = ` + xmr = "88vd4Fxy3AdcUpZp3FChgu5RGBBoEANdpXaB5Bm47JRGKqYbxwQZo1MMwkguQAUDioEPyf4rFK1yMUCgrE7ojVpAVEEzXVD" + + xmrQR = ` █████████████████████████████████████████████ █████████████████████████████████████████████ @@ -44,11 +46,10 @@ const ( █████████████████████████████████████████████ ` - XMR = "88vd4Fxy3AdcUpZp3FChgu5RGBBoEANdpXaB5Bm47JRGKqYbxwQZo1MMwkguQAUDioEPyf4rFK1yMUCgrE7ojVpAVEEzXVD" - BTC = "bc1qk22yx0gfce54gx9csy6dp6kl629wm0m9kscwl8" + btc = "bc1qk22yx0gfce54gx9csy6dp6kl629wm0m9kscwl8" - BTCQR = ` + btcQR = ` █████████████████████████████████████ █████████████████████████████████████ @@ -72,9 +73,9 @@ const ( ` - ETH = "0x10517dcb7f3357aB6888cD6067b12D1ce2727B26" + eth = "0x10517dcb7f3357aB6888cD6067b12D1ce2727B26" - ETHQR = ` + ethQR = ` █████████████████████████████████████ █████████████████████████████████████ @@ -99,3 +100,27 @@ const ( ` ) + +type donateInfo struct { + Address string + QRCode string +} + +func (d donateInfo) String() string { + return d.Address +} + +var ETH donateInfo = donateInfo{ + Address: eth, + QRCode: ethQR, +} + +var BTC donateInfo = donateInfo{ + Address: btc, + QRCode: btcQR, +} + +var XMR donateInfo = donateInfo{ + Address: xmr, + QRCode: xmrQR, +}