kolibri icon indicating copy to clipboard operation
kolibri copied to clipboard

Add navigation guard on `NewChannelVersionPage` if there is no new version of channel on Kolibri Studio

Open jonboiser opened this issue 6 years ago • 2 comments

Observed behavior

The New Version Page is accessible if you go to this route directly

https://github.com/learningequality/kolibri/blob/0beb63c921f4568a228c03fb96f444319818016d/kolibri/plugins/device/assets/src/routes/index.js#L132-L139

If the installed channel is the latest channel, this page doesn't present useful information or actions, and might display some information (e.g. diff stats and version history in an unexpected way)

Expected behavior

If the installed version of a public channel matches the latest version on Kolibri Studio, redirect the user out of this page back to the MANAGE_CHANNEL route for that channel.

User-facing consequences

…

Errors and logs

…

Steps to reproduce

  • Import a channel from Kolibri Studio and then get it's ID from the URL when you navigate to it in the Learn section of the site.
  • Navigate to /content/manage_channel/:channel_id/upgrade - this page should not be accessible since you've downloaded the latest version.
  • Ensure that users are not able to directly navigate to this URL.

Context

…

jonboiser avatar Aug 07 '20 20:08 jonboiser

Wouldn't some feedback to the user be warranted here? :thinking: Being redirected back to Manage channel page without as much as You have the latest version might be confusing and leave user thinking that they missed the step or that the feature is not working...

radinamatic avatar Aug 07 '20 21:08 radinamatic

If the current version matches with the latest version, then just showing The version is up to date and a Go back to the channels button should do the work here. @radinamatic @jonboiser what are your views?

ravvis avatar May 02 '21 13:05 ravvis