json-emacs / json-mode

Major mode for editing JSON files with emacs
314 stars 66 forks source link

Can't enable json-mode for a buffer without a file #55

Closed davazp closed 5 years ago

davazp commented 7 years ago

If I invoke json-mode on a buffer without a file, I will get the following error

Wrong type argument: stringp, nil

I use json-mode to display the answer of a server in graphql-mode, but it broke recently because of this.

findtopher commented 5 years ago

I think this may have been fixed - invoking json-mode in an empty buffer seems to work for me (using the current version of json-mode.el)

davazp commented 5 years ago

Indeed. It seems to work for me as well. Thanks!