Skip to content

Commit

Permalink
Update the renderingMode type to ENUM.
Browse files Browse the repository at this point in the history
  • Loading branch information
ramya18101 committed Dec 9, 2024
1 parent fea4262 commit 77ce174
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion internal/auth0/prompt/expand.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ func expandPromptSettings(data *schema.ResourceData) (*management.PromptRenderin

promptSettings := &management.PromptRendering{}

promptSettings.RenderingMode = value.String(promptRawSettings.GetAttr("rendering_mode"))
promptSettings.RenderingMode = (*management.RenderingMode)(value.String(promptRawSettings.GetAttr("rendering_mode")))
promptSettings.ContextConfiguration = value.Strings(promptRawSettings.GetAttr("context_configuration"))
promptSettings.DefaultHeadTagsDisabled = value.Bool(promptRawSettings.GetAttr("default_head_tags_disabled"))
if data.HasChange("head_tags") {
Expand Down
2 changes: 1 addition & 1 deletion internal/auth0/prompt/resource_screen_render.go
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ func deletePromptScreenRenderer(ctx context.Context, data *schema.ResourceData,
prompt := management.PromptType(promptName)
screen := management.ScreenName(screenName)

promptSettings := &management.PromptRendering{RenderingMode: auth0.String(standardMode)}
promptSettings := &management.PromptRendering{RenderingMode: (*management.RenderingMode)(auth0.String(standardMode))}
if err := api.Prompt.UpdateRendering(ctx, prompt, screen, promptSettings); err != nil {
return diag.FromErr(internalError.HandleAPIError(data, err))
}
Expand Down

0 comments on commit 77ce174

Please sign in to comment.