Skip to content

Commit

Permalink
Fix typos
Browse files Browse the repository at this point in the history
  • Loading branch information
SchrodingersGat committed Nov 21, 2023
1 parent 2491d0a commit 1f32978
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion inventree/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ def testAuth(self):
try:
response = self.get('/user/me/')
except requests.exceptions.HTTPError as e:
logger.fatal(f"Athentication error: {str(type(e))}")
logger.fatal(f"Authentication error: {str(type(e))}")
return False
except Exception as e:
logger.fatal(f"Unhandled server error: {str(type(e))}")
Expand Down
8 changes: 4 additions & 4 deletions inventree/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,7 @@ class MetadataMixin:
"""

@property
def metdata_url(self):
def metadata_url(self):
return os.path.join(self._url, "metadata/")

def getMetadata(self):
Expand All @@ -465,7 +465,7 @@ def getMetadata(self):
logger.error("API version 49 or newer required to access instance metadata")
return {}

response = self._api.get(self.metdata_url)
response = self._api.get(self.metadata_url)

return response['metadata']
else:
Expand All @@ -490,14 +490,14 @@ def setMetadata(self, data, overwrite=False):

if overwrite:
return self._api.put(
self.metdata_url,
self.metadata_url,
data={
"metadata": data,
}
)
else:
return self._api.patch(
self.metdata_url,
self.metadata_url,
data={
"metadata": data
}
Expand Down
2 changes: 1 addition & 1 deletion inventree/currency.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@


class CurrencyManager(object):
"""Class for managing InvenTree currency suppport"""
"""Class for managing InvenTree currency support"""

# Currency API endpoint
CURRENCY_ENDPOINT = 'currency/exchange/'
Expand Down
2 changes: 1 addition & 1 deletion inventree/purchase_order.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ def receive(self, quantity=None, status=10, location=None, batch_code='', serial
"""

if quantity is None:
# Substract number of already received lines from the order quantity
# Subtract number of already received lines from the order quantity
quantity = self.quantity - self.received

if location is None:
Expand Down
2 changes: 1 addition & 1 deletion inventree/sales_order.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class SalesOrder(
inventree.base.InventreeObject,
inventree.base.StatusMixin
):
""" Class respresenting the SalesOrder database model """
""" Class representing the SalesOrder database model """

URL = 'order/so'

Expand Down
2 changes: 1 addition & 1 deletion inventree/stock.py
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ def upload_result(cls, api, stock_item, test, result, **kwargs):
'value': value,
}

# Send the data to the serever
# Send the data to the server
if api.post(cls.URL, data, files=files):
logging.info(f"Uploaded test result: '{test}'")
ret = True
Expand Down
2 changes: 1 addition & 1 deletion test/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ services:

inventree-py-test-server:
container_name: inventree-py-test-server
image: inventree/inventree:latest
image: inventree/inventree:0.12.8
ports:
# Expose internal port 8000 on external port 12345
- 12345:8000
Expand Down

0 comments on commit 1f32978

Please sign in to comment.