node-mapnik
node-mapnik copied to clipboard
Format not handled correctly in image.save
Companion to #527: if a faulty format option is passed the expectation is that the function will throw (rather than just return an error in the callback). But based on how https://github.com/mapnik/node-mapnik/blob/master/src/mapnik_image.cpp#L3361-L3377 works a faulty format option will sneak through into the async machinery. This makes it inconsistent to the sync function in behavior with an invalid format.