Remember color div local storage SOLVED

I have a code that when a div is clicked the color changes, the problem is that it should toggle and not stay in the color forever. I should be able to click it again to give its original color back.

This fiddle shows how it works. But I want to be able to click on the gray one and turn them back to there original state!

https://jsfiddle.net/pyhrfq4z/

Got the answer from here for people who might be interested: