Skip to content
Snippets Groups Projects
Commit f133395d authored by Richard T. Carback III's avatar Richard T. Carback III
Browse files

Add timestamp changes

parent c29b3681
No related branches found
No related tags found
3 merge requests!127Modify internal password generation to base it off the user's password,!124Update for single DB cipher object,!109Project/haven beta
...@@ -517,12 +517,11 @@ func (rsCB *RemoteStore) Write(path string, data []byte) error { ...@@ -517,12 +517,11 @@ func (rsCB *RemoteStore) Write(path string, data []byte) error {
// - JSON of [bindings.RemoteStoreReport] (Uint8Array). // - JSON of [bindings.RemoteStoreReport] (Uint8Array).
// - Catches any thrown errors (of type Error) and returns it as an error. // - Catches any thrown errors (of type Error) and returns it as an error.
func (rsCB *RemoteStore) GetLastModified(path string) (string, error) { func (rsCB *RemoteStore) GetLastModified(path string) (string, error) {
fn := func() js.Value { return rsCB.getLastModified(path) } v, err := utils.Await(rsCB.getLastModified(path))
v, err := exception.RunAndCatch(fn)
if err != nil { if err != nil {
return "", err return "", js.Error{Value: err[0]}
} }
return v.String(), err return v[0].String(), nil
} }
// GetLastWrite implements [bindings.RemoteStore.GetLastWrite() // GetLastWrite implements [bindings.RemoteStore.GetLastWrite()
...@@ -531,12 +530,11 @@ func (rsCB *RemoteStore) GetLastModified(path string) (string, error) { ...@@ -531,12 +530,11 @@ func (rsCB *RemoteStore) GetLastModified(path string) (string, error) {
// - JSON of [bindings.RemoteStoreReport] (Uint8Array). // - JSON of [bindings.RemoteStoreReport] (Uint8Array).
// - Catches any thrown errors (of type Error) and returns it as an error. // - Catches any thrown errors (of type Error) and returns it as an error.
func (rsCB *RemoteStore) GetLastWrite() (string, error) { func (rsCB *RemoteStore) GetLastWrite() (string, error) {
fn := func() js.Value { return rsCB.getLastWrite() } v, err := utils.Await(rsCB.getLastWrite())
v, err := exception.RunAndCatch(fn)
if err != nil { if err != nil {
return "", err return "", js.Error{Value: err[0]}
} }
return v.String(), err return v[0].String(), nil
} }
// ReadDir implements [bindings.RemoteStore.ReadDir] // ReadDir implements [bindings.RemoteStore.ReadDir]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment