Adds support for extensions that changed name in package.json.

If an extension adds a package.json with a name that is different
from its pre-package.json GitHub-derived name, the user would
previously end up with two extensions. This change will delete
the old extension.

This is a fix for #4133 and I tested it with the specific case listed in that
issue.