ui/gui.go
func (h *Handler) GetGUISettings(tkn string) (map[string]interface{}, error) {
	logger := h.logger.Add("method", "GetGUISettings")

	if !h.token.Check(tkn) {
		logger.Warn("access denied")
		return nil, ErrAccessDenied
	}

	retStr, err := data.ReadSetting(h.db.Querier, data.SettingGUI)
	if err != nil {
		logger.Error(err.Error())
		return nil, ErrInternal
	}

	ret := make(map[string]interface{})

	err = json.Unmarshal([]byte(retStr), &ret)
	if err != nil {
		logger.Error(err.Error())
		return nil, ErrInternal
	}

	return ret, nil
}
func (h *Handler) GetGUISettings(tkn string) (map[string]interface{}, error) {
	logger := h.logger.Add("method", "GetGUISettings")

	if !h.token.Check(tkn) {
		logger.Warn("access denied")
		return nil, ErrAccessDenied
	}

	retStr, err := data.ReadSetting(h.db.Querier, data.SettingGUI)
	if err != nil {
		logger.Error(err.Error())
		return nil, ErrInternal
	}

	ret := make(map[string]interface{})

	err = json.Unmarshal([]byte(retStr), &ret)
	if err != nil {
		logger.Error(err.Error())
		return nil, ErrInternal
	}

	return ret, nil
}
// GetGUISettings returns gui settings.