fisadev / vim-isort

Vim plugin to sort python imports using https://github.com/timothycrosley/isort
MIT License
219 stars 32 forks source link

Fixed the error when the file is skipped #20

Closed zerc closed 5 years ago

zerc commented 6 years ago

Hey, I just noticed that when the file is manually skipped i.e. isort:skip_file "token" in the file, the plugin will throw the annoying error like this:

screen shot 2017-11-17 at 12 30 30

I just added a check for that to exit if there is no output (which usually means that the data wasn't processed i.e. skipped).

fisadev commented 5 years ago

Hi! Sorry for the delay. (wow, almost a year). I've just merged a PR which fixes this, taking into account that currently output will exist and will be None.

fisadev commented 5 years ago

The merged PR, for reference: https://github.com/fisadev/vim-isort/pull/26