Single type for entry submission on error loses entry object I have created a contact form inside a single entry type 'contact' for front end submissions.
This lets me display editing options for title and body and display the form.

When submitting the form, the entry object ( eg entry.title ) disappears and no title or body  content is shown - just the form with its corresponding errors.

So submitting it seems to lose the entry - is this because it is returning the saved entry model and not the single that it is on?
From the README:


  If there is a validation error on the entry, then the page will be reloaded with an entry variable available to it...


You can override the variable name by setting the entryVariable config setting, as follows:

&lt;?php

// File: craft/config/guestentries.php

return [
    'entryVariable' =&gt; 'guestEntry',
];


Once you've done that, the page entry model will be available as entry, and the "guest entries" entry model (containing any validation errors) will be available as guestEntry.