I save the data from the form to the local storage, and then send it to the server. If the connection is lost, the data must be written to another storage, so that, when the connection is restored, it must be sent and transferred to the first storage (successful). This option does not work, because both storages refer to the same object.
SucessStorage = localStorage; UnsucessStorage = localStorage;