You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: resolver_mutation_configure.go
    path of file: ./repos/stash/internal/api
    
    the code of the file until where you have to start completion: package api

import (
	"context"
	"errors"
	"fmt"
	"path/filepath"
	"regexp"

	"github.com/stashapp/stash/internal/manager"
	"github.com/stashapp/stash/internal/manager/config"
	"github.com/stashapp/stash/pkg/fsutil"
	"github.com/stashapp/stash/pkg/logger"
	"github.com/stashapp/stash/pkg/models"
)

var ErrOverriddenConfig = errors.New("cannot set overridden value")

func (r *mutationResolver) Setup(ctx context.Context, input manager.SetupInput) (bool, error) {
	err := manager.GetInstance().Setup(ctx, input)
	return err == nil, err
}

func (r *mutationResolver) Migrate(ctx context.Context, input manager.MigrateInput) (bool, error) {
	err := manager.GetInstance().Migrate(ctx, input)
	return err == nil, err
}

func (r *mutationResolver) ConfigureGen
    
func (r *mutationResolver) ConfigureInterface(ctx context.Context, input ConfigInterfaceInput) (*ConfigInterfaceResult, error) {
	c := config.GetInstance()

	setBool := func(key string, v *bool) {
		if v != nil {
			c.Set(key, *v)
		}
	}

	setString := func(key string, v *string) {
		if v != nil {
			c.Set(key, *v)
		}
	}

	if input.MenuItems != nil {
		c.Set(config.MenuItems, input.MenuItems)
	}

	setBool(config.SoundOnPreview, input.SoundOnPreview)
	setBool(config.WallShowTitle, input.WallShowTitle)

	setBool(config.NoBrowser, input.NoBrowser)

	setBool(config.NotificationsEnabled, input.NotificationsEnabled)

	setBool(config.ShowScrubber, input.ShowScrubber)

	if input.WallPlayback != nil {
		c.Set(config.WallPlayback, *input.WallPlayback)
	}

	if input.MaximumLoopDuration != nil {
		c.Set(config.MaximumLoopDuration, *input.MaximumLoopDuration)
	}

	setBool(config.AutostartVideo, input.AutostartVideo)
	setBool(config.ShowStudioAsText, input.ShowStudioAsText)
	setBool(config.AutostartVideoOnPlaySelected, input.AutostartVideoOnPlaySelected)
	setBool(config.ContinuePlaylistDefault, input.ContinuePlaylistDefault)

	if input.Language != nil {
		c.Set(config.Language, *input.Language)
	}

	if input.ImageLightbox != nil {
		options := input.ImageLightbox

		if options.SlideshowDelay != nil {
			c.Set(config.ImageLightboxSlideshowDelay, *options.SlideshowDelay)
		}

		setString(config.ImageLightboxDisplayModeKey, (*string)(options.DisplayMode))
		setBool(config.ImageLightboxScaleUp, options.ScaleUp)
		setBool(config.ImageLightboxResetZoomOnNav, options.ResetZoomOnNav)
		setString(config.ImageLightboxScrollModeKey, (*string)(options.ScrollMode))

		if options.ScrollAttemptsBeforeChange != nil {
			c.Set(config.ImageLightboxScrollAttemptsBeforeChange, *options.ScrollAttemptsBeforeChange)
		}
	}

	if input.CSS != nil {
		c.SetCSS(*input.CSS)
	}

	setBool(config.CSSEnabled, input.CSSEnabled)

	if input.Javascript != nil {
		c.SetJavascript(*input.Javascript)
	}

	setBool(config.JavascriptEnabled, input.JavascriptEnabled)

	if input.CustomLocales != nil {
		c.SetCustomLocales(*input.CustomLocales)
	}

	setBool(config.CustomLocalesEnabled, input.CustomLocalesEnabled)

	if input.DisableDropdownCreate != nil {
		ddc := input.DisableDropdownCreate
		setBool(config.DisableDropdownCreatePerformer, ddc.Performer)
		setBool(config.DisableDropdownCreateStudio, ddc.Studio)
		setBool(config.DisableDropdownCreateTag, ddc.Tag)
		setBool(config.DisableDropdownCreateMovie, ddc.Movie)
	}

	if input.HandyKey != nil {
		c.Set(config.HandyKey, *input.HandyKey)
	}

	if input.FunscriptOffset != nil {
		c.Set(config.FunscriptOffset, *input.FunscriptOffset)
	}

	if input.UseStashHostedFunscript != nil {
		c.Set(config.UseStashHostedFunscript, *input.UseStashHostedFunscript)
	}

	if err := c.Write(); err != nil {
		return makeConfigInterfaceResult(), err
	}

	return makeConfigInterfaceResult(), nil
}