Fixed a couple of typos and command ordering issues.
wq