Commit a95c3df5 authored by Morgan McMillian's avatar Morgan McMillian

fix syntax error in user lookups issue #37

parent c9be0256
......@@ -63,7 +63,7 @@ def save_cb(room, event):
def drop_cb(room, event):
try:
user = Users.query.filter(Users.matrix_id=event['sender']).one_or_none()
user = Users.query.filter(Users.matrix_id == event['sender']).one_or_none()
if user is not None:
db_session.delete(user)
db_session.commit()
......@@ -79,7 +79,7 @@ def drop_cb(room, event):
def status_cb(room, event):
try:
user = Users.query.filter(Users.matrix_id=event['sender']).one_or_none()
user = Users.query.filter(Users.matrix_id == event['sender']).one_or_none()
if user is None:
reply = "You are currently not authorized on pnut.io"
else:
......@@ -99,7 +99,7 @@ def status_cb(room, event):
if __name__ == "__main__":
logging.basicConfig(level=logging.DEBUG)
logging.basicConfig(level=logging.INFO)
with open("config.yaml", "rb") as config_file:
config = yaml.load(config_file)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment