Skip to content

Commit

Permalink
Replace hardcoded config in Item with package config value
Browse files Browse the repository at this point in the history
  • Loading branch information
campb303 committed Jun 10, 2021
1 parent 9f545fe commit b67ee91
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions src/webqueue2api/parser/item.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
from dateutil.parser import parse
from dateutil import tz
from typing import Union



#------------------------------------------------------------------------------#
# Configuration
#------------------------------------------------------------------------------#
queueDirectory = "/home/pier/e/queue/Mail"
from .config import config



Expand Down Expand Up @@ -51,7 +45,7 @@ def __init__(self, queue: str, number: int) -> None:
raise ValueError(" Could not convert \"" +
number + "\" to an integer")

self.__path = "/".join([queueDirectory, self.queue, str(self.number)])
self.__path = "/".join([config.queue_directory, self.queue, str(self.number)])
self.lastUpdated = self.__getLastUpdated()
self.__rawItem = self.__getRawItem()
self.headers = self.__parseHeaders()
Expand Down

0 comments on commit b67ee91

Please sign in to comment.