mirror of
https://github.com/matrix-org/dendrite
synced 2024-11-18 15:50:52 +01:00
Error when recaptcha enabled with empty configs (#786)
This commit is contained in:
parent
d63d2a50cd
commit
bf5efbc31f
1 changed files with 5 additions and 0 deletions
|
@ -498,6 +498,11 @@ func (config *Dendrite) checkMatrix(configErrs *configErrors) {
|
||||||
checkNotEmpty(configErrs, "matrix.server_name", string(config.Matrix.ServerName))
|
checkNotEmpty(configErrs, "matrix.server_name", string(config.Matrix.ServerName))
|
||||||
checkNotEmpty(configErrs, "matrix.private_key", string(config.Matrix.PrivateKeyPath))
|
checkNotEmpty(configErrs, "matrix.private_key", string(config.Matrix.PrivateKeyPath))
|
||||||
checkNotZero(configErrs, "matrix.federation_certificates", int64(len(config.Matrix.FederationCertificatePaths)))
|
checkNotZero(configErrs, "matrix.federation_certificates", int64(len(config.Matrix.FederationCertificatePaths)))
|
||||||
|
if config.Matrix.RecaptchaEnabled {
|
||||||
|
checkNotEmpty(configErrs, "matrix.recaptcha_public_key", string(config.Matrix.RecaptchaPublicKey))
|
||||||
|
checkNotEmpty(configErrs, "matrix.recaptcha_private_key", string(config.Matrix.RecaptchaPrivateKey))
|
||||||
|
checkNotEmpty(configErrs, "matrix.recaptcha_siteverify_api", string(config.Matrix.RecaptchaSiteVerifyAPI))
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// checkMedia verifies the parameters media.* are valid.
|
// checkMedia verifies the parameters media.* are valid.
|
||||||
|
|
Loading…
Reference in a new issue