diff options
| author | 2024-05-27 19:03:54 +0200 | |
|---|---|---|
| committer | 2024-05-27 17:03:54 +0000 | |
| commit | a276b1ca06ce3ebfc201b9aaf3aa8c37c98fe584 (patch) | |
| tree | 861d2c9c7440fd6b602f46a3e18a55b4c31718d1 /internal/api/client | |
| parent | [experiment] add alternative wasm sqlite3 implementation available via build-... (diff) | |
| download | gotosocial-a276b1ca06ce3ebfc201b9aaf3aa8c37c98fe584.tar.xz | |
[feature/frontend] Let admins send test email to validate SMTP config (#2934)
* [feature/frontend] Let admins send test email to validate SMTP config
* wee
Diffstat (limited to 'internal/api/client')
| -rw-r--r-- | internal/api/client/admin/emailtest.go | 13 | 
1 files changed, 12 insertions, 1 deletions
diff --git a/internal/api/client/admin/emailtest.go b/internal/api/client/admin/emailtest.go index 42b405ce7..9b214a926 100644 --- a/internal/api/client/admin/emailtest.go +++ b/internal/api/client/admin/emailtest.go @@ -54,6 +54,12 @@ import (  //		in: formData  //		description: The email address that the test email should be sent to.  //		type: string +//		required: true +//	- +//		name: message +//		in: formData +//		description: Optional message to include in the email. +//		type: string  //  //	security:  //	- OAuth2 Bearer: @@ -115,7 +121,12 @@ func (m *Module) EmailTestPOSTHandler(c *gin.Context) {  		return  	} -	errWithCode := m.processor.Admin().EmailTest(c.Request.Context(), authed.Account, email.Address) +	errWithCode := m.processor.Admin().EmailTest( +		c.Request.Context(), +		authed.Account, +		email.Address, +		form.Message, +	)  	if errWithCode != nil {  		apiutil.ErrorHandler(c, errWithCode, m.processor.InstanceGetV1)  		return  | 
