Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support VFS methods with no argument #788

Closed
mahsashadi opened this issue Dec 28, 2021 · 2 comments
Closed

Support VFS methods with no argument #788

mahsashadi opened this issue Dec 28, 2021 · 2 comments
Assignees

Comments

@mahsashadi
Copy link

mahsashadi commented Dec 28, 2021

Hi @andersevenrud
Due to this comment, imagine we have capabilities method with no argument in client-sie:
method call:

vfs.capabilities();

osjs-client/src/vfs.js

export const capabilities = (adapter, mount) => () => {
  const cached = capabilityCache[mount.name];
  if (cached) {
    return Promise.resolve(cached);
  }
  return adapter.capabilities(mount)
    .then(capabilities => {
      capabilityCache[mount.name] = capabilities;
      return capabilities;
    });
};

osjs-client/src/adapters/vfs/system.js

    capabilities: () => request('capabilities', {}, 'json').then(({body}) => {
      return body;
    }),

But server-side needs path argument to find the mountpoint here. I 've tried to solve it, but did not come up with solution!

@mahsashadi
Copy link
Author

@andersevenrud sorry for re-mentioning

@andersevenrud andersevenrud self-assigned this Apr 10, 2022
@andersevenrud
Copy link
Member

Closing because #804 superseeds this and there's already an ongoing discussion :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants