Skip to content

Commit

Permalink
Bugfix running through the onboarding process
Browse files Browse the repository at this point in the history
  • Loading branch information
kevindice committed Jan 15, 2019
1 parent caffd47 commit 7d57b55
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/components/FavoritesBar/FavoritesBar.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,20 @@ const mapStateToProps = (store) => {
const username = getJupyterHubUsername(store);
const beocatSystem = getBeocatSystems(store)[0];

const isBeocatSystem = store.router.pathname.indexOf('beocat') !== -1;

if (!isBeocatSystem) {
return {
username,
beocatSystemUrlPrefix: '',
isBeocatSystem,
}
}

return {
username,
beocatSystemUrlPrefix: `/files/browse/${beocatSystem.provider}/${beocatSystem.id}/`,
isBeocatSystem: store.router.pathname.indexOf('beocat') !== -1,
isBeocatSystem,
};
};

Expand Down
2 changes: 2 additions & 0 deletions src/store/files/sagas.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,8 @@ function* uploadFile(action) {
const csrfToken = yield select(getCsrf);
const ProviderService = resolveProviderService(action.path);
yield call(ProviderService.uploadFile, csrfToken, action.file, action.path);
yield call(delay, 3000); // Arbitrary delay for consistency
yield put(fileListActions.pending(action.path))
} catch (e) {
console.log(e);
// Do something to handle the error
Expand Down

0 comments on commit 7d57b55

Please sign in to comment.