Fix inline editor

This fixes an issue where you saved a change but then deleted it.
But then you decided to edit the same file again, this resulted in
it restoring from the cache.

Another example is editing a file then restoring it to it's previous state.
Because it was cached it would restore it from the cache which is not
was supposed to be happening.

The cause of this was eraseEditableContentItem missing a call to
_getEditableContentKey.

Bug: Issue 10371
Change-Id: I47e4ca216804f0a86b1cec4ac549bb0599e17cb2
(cherry picked from commit 621d8b3457c1d6521709c0dce6af6ad6ea4b0aa9)
diff --git a/polygerrit-ui/app/elements/shared/gr-storage/gr-storage.js b/polygerrit-ui/app/elements/shared/gr-storage/gr-storage.js
index 62080a1..c425609 100644
--- a/polygerrit-ui/app/elements/shared/gr-storage/gr-storage.js
+++ b/polygerrit-ui/app/elements/shared/gr-storage/gr-storage.js
@@ -72,7 +72,7 @@
     },
 
     eraseEditableContentItem(key) {
-      this._storage.removeItem(key);
+      this._storage.removeItem(this._getEditableContentKey(key));
     },
 
     getPreferences() {
diff --git a/polygerrit-ui/app/elements/shared/gr-storage/gr-storage_test.html b/polygerrit-ui/app/elements/shared/gr-storage/gr-storage_test.html
index b7d73d4..6b89af2 100644
--- a/polygerrit-ui/app/elements/shared/gr-storage/gr-storage_test.html
+++ b/polygerrit-ui/app/elements/shared/gr-storage/gr-storage_test.html
@@ -188,7 +188,7 @@
 
       // eraseEditableContentItem performs as expected.
       element.eraseEditableContentItem(key);
-      assert.isNotOk(element._storage.getItem(key));
+      assert.isNotOk(element._storage.getItem(computedKey));
     });
   });
 </script>