forked from vieter-v/vieter
Fix for segfault
This commit is contained in:
parent
6c435c2a1e
commit
57c4af0aaf
4 changed files with 39 additions and 38 deletions
|
|
@ -4,12 +4,12 @@ import json
|
|||
import net.urllib
|
||||
|
||||
struct Container {
|
||||
id string
|
||||
names []string
|
||||
id string
|
||||
names []string
|
||||
}
|
||||
|
||||
pub fn containers() ?[]Container {
|
||||
res := docker.get(urllib.parse('/containers/json') ?) ?
|
||||
res := get(urllib.parse('/containers/json') ?) ?
|
||||
|
||||
return json.decode([]Container, res.text)
|
||||
return json.decode([]Container, res.text) or {}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue