Put in order · Vibe coding with Claude Code course · Module 7: LinkedIn clone
Sorting: Steps of the updateProfile action
Arrange the steps of the updateProfile Server Action:
Items to put in order
- getCurrentUser() determines whose profile it is
- revalidatePath, then redirect to the profile page
- saveProfile saves the cleaned data
- profileSchema.safeParse(values), and on an error returning { values, errors }
- Reading the four expected fields from FormData
You can check the correct answer by solving this task in the CodeWorlds game.