Fix js snapshot operations

JS snapshot operations (snapshot, delete-snapshot and active-snapshot) don't use the given name but the constant string "name".

The problem is that the `parseOption` method sets the name property to the name of the parsed option instead of the value.  This pull request fixes this.