mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-11 20:57:31 +00:00
fix: smtp provider (#8610)
There were some problems after changing from SMTP providers to email providers (https://github.com/zitadel/zitadel/pull/8545): - panic (nil pointer) on SMTP provider retrieval for HTTP configs - old SMTP configuration created before the multi SMTP configurations (without id) - were not projected / listed - could not be always be activated - Console treated HTTP configs as SMTP --------- Co-authored-by: Livio Spring <livio.a@gmail.com>
This commit is contained in:
@@ -14,26 +14,26 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
prepareSMTPConfigStmt = `SELECT projections.smtp_configs3.creation_date,` +
|
||||
` projections.smtp_configs3.change_date,` +
|
||||
` projections.smtp_configs3.resource_owner,` +
|
||||
` projections.smtp_configs3.sequence,` +
|
||||
` projections.smtp_configs3.id,` +
|
||||
` projections.smtp_configs3.state,` +
|
||||
` projections.smtp_configs3.description,` +
|
||||
` projections.smtp_configs3_smtp.id,` +
|
||||
` projections.smtp_configs3_smtp.tls,` +
|
||||
` projections.smtp_configs3_smtp.sender_address,` +
|
||||
` projections.smtp_configs3_smtp.sender_name,` +
|
||||
` projections.smtp_configs3_smtp.reply_to_address,` +
|
||||
` projections.smtp_configs3_smtp.host,` +
|
||||
` projections.smtp_configs3_smtp.username,` +
|
||||
` projections.smtp_configs3_smtp.password,` +
|
||||
` projections.smtp_configs3_http.id,` +
|
||||
` projections.smtp_configs3_http.endpoint` +
|
||||
` FROM projections.smtp_configs3` +
|
||||
` LEFT JOIN projections.smtp_configs3_smtp ON projections.smtp_configs3.id = projections.smtp_configs3_smtp.id AND projections.smtp_configs3.instance_id = projections.smtp_configs3_smtp.instance_id` +
|
||||
` LEFT JOIN projections.smtp_configs3_http ON projections.smtp_configs3.id = projections.smtp_configs3_http.id AND projections.smtp_configs3.instance_id = projections.smtp_configs3_http.instance_id` +
|
||||
prepareSMTPConfigStmt = `SELECT projections.smtp_configs4.creation_date,` +
|
||||
` projections.smtp_configs4.change_date,` +
|
||||
` projections.smtp_configs4.resource_owner,` +
|
||||
` projections.smtp_configs4.sequence,` +
|
||||
` projections.smtp_configs4.id,` +
|
||||
` projections.smtp_configs4.state,` +
|
||||
` projections.smtp_configs4.description,` +
|
||||
` projections.smtp_configs4_smtp.id,` +
|
||||
` projections.smtp_configs4_smtp.tls,` +
|
||||
` projections.smtp_configs4_smtp.sender_address,` +
|
||||
` projections.smtp_configs4_smtp.sender_name,` +
|
||||
` projections.smtp_configs4_smtp.reply_to_address,` +
|
||||
` projections.smtp_configs4_smtp.host,` +
|
||||
` projections.smtp_configs4_smtp.username,` +
|
||||
` projections.smtp_configs4_smtp.password,` +
|
||||
` projections.smtp_configs4_http.id,` +
|
||||
` projections.smtp_configs4_http.endpoint` +
|
||||
` FROM projections.smtp_configs4` +
|
||||
` LEFT JOIN projections.smtp_configs4_smtp ON projections.smtp_configs4.id = projections.smtp_configs4_smtp.id AND projections.smtp_configs4.instance_id = projections.smtp_configs4_smtp.instance_id` +
|
||||
` LEFT JOIN projections.smtp_configs4_http ON projections.smtp_configs4.id = projections.smtp_configs4_http.id AND projections.smtp_configs4.instance_id = projections.smtp_configs4_http.instance_id` +
|
||||
` AS OF SYSTEM TIME '-1 ms'`
|
||||
prepareSMTPConfigCols = []string{
|
||||
"creation_date",
|
||||
|
Reference in New Issue
Block a user