maryvilledev / codesplainUI

Web app for breaking down and annotating Python 3 source code.
https://www.codesplain.io
GNU General Public License v3.0
2 stars 2 forks source link

Handle users who have no index.json #412

Closed Hopding closed 7 years ago

Hopding commented 7 years ago

Description

This PR causes an error to be thrown if a GET for a user's index.json returns a response containing this xml:

<Error><Code>NoSuchKey</Code><Message>The specified key does not exist.</Message>

and the user's snippet list menu option is disabled until they possess snippet(s) & an index file.

Motivation and Context

Fixes #411. This PR solves the problem of users with no index.json getting an infinite empty list of snippets.

Checklist:

Screenshots:

User with no snippets

screen shot 2017-04-17 at 6 07 29 pm

User with snippets

screen shot 2017-04-17 at 6 08 01 pm