Ensure source map object is written as JSON

Resolves gh-3