about summary refs log tree commit diff stats
path: root/adapter/protocol
diff options
context:
space:
mode:
authorbptato <nincsnevem662@gmail.com>2023-12-16 14:53:34 +0100
committerbptato <nincsnevem662@gmail.com>2023-12-16 14:53:41 +0100
commit3f2bc1069142ae13f9991102a0c01cd1291b08e8 (patch)
tree0c5152368425d50931589e9d41d3f33ae54a1162 /adapter/protocol
parent25988dfa3bd77c16eb29bdb8087d286c66c4cd7a (diff)
downloadchawan-3f2bc1069142ae13f9991102a0c01cd1291b08e8.tar.gz
Fix compilation on Nim 1.6.14
Diffstat (limited to 'adapter/protocol')
-rw-r--r--adapter/protocol/data.nim5
-rw-r--r--adapter/protocol/file.nim1
-rw-r--r--adapter/protocol/ftp.nim5
-rw-r--r--adapter/protocol/gopher.nim5
-rw-r--r--adapter/protocol/http.nim5
5 files changed, 16 insertions, 5 deletions
diff --git a/adapter/protocol/data.nim b/adapter/protocol/data.nim
index 4f5da2e8..5f43f9da 100644
--- a/adapter/protocol/data.nim
+++ b/adapter/protocol/data.nim
@@ -1,4 +1,7 @@
-import std/envvars
+when NimMajor >= 2:
+  import std/envvars
+else:
+  import std/os
 import std/base64
 import std/strutils
 
diff --git a/adapter/protocol/file.nim b/adapter/protocol/file.nim
index fbd14479..3513ab3c 100644
--- a/adapter/protocol/file.nim
+++ b/adapter/protocol/file.nim
@@ -2,7 +2,6 @@ import std/algorithm
 import std/os
 import std/streams
 import std/times
-import std/envvars
 
 import dirlist
 
diff --git a/adapter/protocol/ftp.nim b/adapter/protocol/ftp.nim
index 064c0396..d3a91e96 100644
--- a/adapter/protocol/ftp.nim
+++ b/adapter/protocol/ftp.nim
@@ -1,4 +1,7 @@
-import std/envvars
+when NimMajor >= 2:
+  import std/envvars
+else:
+  import std/os
 import std/options
 import std/strutils
 
diff --git a/adapter/protocol/gopher.nim b/adapter/protocol/gopher.nim
index 7742613c..f266e857 100644
--- a/adapter/protocol/gopher.nim
+++ b/adapter/protocol/gopher.nim
@@ -1,4 +1,7 @@
-import std/envvars
+when NimMajor >= 2:
+  import std/envvars
+else:
+  import std/os
 
 import curl
 import curlerrors
diff --git a/adapter/protocol/http.nim b/adapter/protocol/http.nim
index d973bd1d..07e1d0ad 100644
--- a/adapter/protocol/http.nim
+++ b/adapter/protocol/http.nim
@@ -1,4 +1,7 @@
-import std/envvars
+when NimMajor >= 2:
+  import std/envvars
+else:
+  import std/os
 import std/strutils
 
 import curl