Skip to content

Commit 28f86a9

Browse files
committed
fixes #13 POST geojson was not working
1 parent f90c7f1 commit 28f86a9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/lib.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ function replacefiles(str) {
2727
module.exports = function(options) {
2828
return new Promise(function(resolve, reject) {
2929
options = options || {};
30-
options.geojson = options.geojson || '';
30+
options.geojson = (options.geojson && (typeof options.geojson === 'string' ? options.geojson : JSON.stringify(options.geojson))) || '';
3131
options.height = options.height || 600;
3232
options.width = options.width || 800;
3333
options.center = options.center || '';

0 commit comments

Comments
 (0)