aboutsummaryrefslogtreecommitdiff
path: root/bcst/resource.py
diff options
context:
space:
mode:
authorLoic Guegan <manzerbredes@mailbox.org>2020-04-22 10:03:04 +0200
committerLoic Guegan <manzerbredes@mailbox.org>2020-04-22 10:03:04 +0200
commit586e35e3906214fc964714dd60091b290400ba1d (patch)
tree34fcc2b46d8a95abadd454773edcc94c48df6ffc /bcst/resource.py
parent24ef10da650d091e67bd82ec3f9b329bcee1a15e (diff)
Clean theme and improve api
Diffstat (limited to 'bcst/resource.py')
-rw-r--r--bcst/resource.py23
1 files changed, 0 insertions, 23 deletions
diff --git a/bcst/resource.py b/bcst/resource.py
deleted file mode 100644
index 342e08a..0000000
--- a/bcst/resource.py
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/usr/bin/env python
-
-from os import path
-import json
-
-
-class Resource:
- def __init__(self, resource):
- self.resource=resource
- # Read data
- try:
- with open(resource,'r') as f:
- self.data=f.read()
- except IOError:
- print("Unable to found "+resource)
- exit(1)
- # Decode data
- try:
- self.json=json.loads(self.data)
- except:
- print("Unable to read json from "+resource)
- exit(1)
-