Fix unused import warning on Unix systems

The NimbleError exception from the version module is being used only on
Windows platforms in the packageinstaller.nim file. Conditional import
of the module is used to fix the warning.

Related to #680
This commit is contained in:
Ivan Bobev 2019-08-07 23:03:14 +03:00 committed by Dominik Picheta
commit 427b412ff9

View file

@ -3,7 +3,10 @@
import os, strutils, sets, json import os, strutils, sets, json
# Local imports # Local imports
import version, cli, options, tools import cli, options, tools
when defined(windows):
import version
when not declared(initHashSet) or not declared(toHashSet): when not declared(initHashSet) or not declared(toHashSet):
import common import common