Skip to content

Commit 7156a66

Browse files
Update 13/umbraco-forms/developer/working-with-data.md
Co-authored-by: Ronald Barendse <[email protected]>
1 parent d997248 commit 7156a66

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

13/umbraco-forms/developer/working-with-data.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,9 +134,9 @@ Here is sample code for how to get the record in a view.
134134
Record? record;
135135
string submittedEmail;
136136

137-
if (TempData["UmbracoFormSubmitted"] != null)
137+
if (Guid.TryParse(TempData["UmbracoFormSubmitted"]?.ToString(), out Guid formId) &&
138+
Guid.TryParse(TempData["Forms_Current_Record_id"]?.ToString(), out Guid recordId))
138139
{
139-
Guid.TryParse(TempData["UmbracoFormSubmitted"]?.ToString(), out formId);
140140

141141
form = _formService.Get(formId);
142142

0 commit comments

Comments
 (0)