Update queryStringToArray.js

1) Changed to Constructor with literal object return.
2) Add toObject method