popcodeorg / popcodeorg/popcode

Degrade gracefully if local storage isn’t available

Open
#1,380 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

error help wanted
Dominant language
JavaScript
Stars
191
Forks
143
Avg merge
4d 11h
Merged PRs (30d)
5

Description

Currently the rehydrateProject() function throws an error if localStorage is null. Given that Popcode’s core functionality does not rely on localStorage, we should fall back gracefully to a noop for the project grace period feature.


Error in Popcode

TypeError in /
Cannot read property 'getItem' of null

View on Bugsnag

Stacktrace

webpack:///src/clients/localStorage.js:12 - W5mC.t.b

View full stacktrace

Created by Matthew Brown via Bugsnag

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with rehydrateProject() in src/clients/localStorage.js, especially the access reported at line 12. Trace how the project grace period feature uses localStorage, then verify that a null localStorage value no longer throws and instead leaves that feature as a noop while Popcode’s core functionality remains available.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.