feat: expose if task comments are enabled or not in /info

This commit is contained in:
kolaente 2021-09-26 13:37:57 +02:00
parent 56efbdc297
commit ae8db176db
No known key found for this signature in database
GPG key ID: F40E70337AB24C9B

View file

@ -51,6 +51,7 @@ type vikunjaInfos struct {
AuthInfo authInfo `json:"auth"` AuthInfo authInfo `json:"auth"`
EmailRemindersEnabled bool `json:"email_reminders_enabled"` EmailRemindersEnabled bool `json:"email_reminders_enabled"`
UserDeletionEnabled bool `json:"user_deletion_enabled"` UserDeletionEnabled bool `json:"user_deletion_enabled"`
TaskCommentsEnabled bool `json:"task_comments_enabled"`
} }
type authInfo struct { type authInfo struct {
@ -93,6 +94,7 @@ func Info(c echo.Context) error {
CaldavEnabled: config.ServiceEnableCaldav.GetBool(), CaldavEnabled: config.ServiceEnableCaldav.GetBool(),
EmailRemindersEnabled: config.ServiceEnableEmailReminders.GetBool(), EmailRemindersEnabled: config.ServiceEnableEmailReminders.GetBool(),
UserDeletionEnabled: config.ServiceEnableUserDeletion.GetBool(), UserDeletionEnabled: config.ServiceEnableUserDeletion.GetBool(),
TaskCommentsEnabled: config.ServiceEnableTaskComments.GetBool(),
AvailableMigrators: []string{ AvailableMigrators: []string{
(&vikunja_file.FileMigrator{}).Name(), (&vikunja_file.FileMigrator{}).Name(),
}, },