fixing post and db and removing unused stuff

This commit is contained in:
JesseBot 2019-01-11 07:55:25 +00:00
parent b721b212eb
commit 6fcbdaf096
2 changed files with 1 additions and 16 deletions

View file

@ -32,7 +32,6 @@ def add_new_band(band):
# Save (commit) the changes
conn.commit()
except Exception as e:
log.error("Error: {0}".format(e))
return e
# close connection

View file

@ -78,22 +78,8 @@ def next_band_submit():
# if success redirect back to main page
if add_new_band == "Success":
redirect("/next-band")
# else error
return "<p>THERE WAS AN ERROR</p>"
@route('/next-band-get-all')
def next_band_get_all():
# Grab site specific information - YAML
globals = get_global_variables()
cmd = "./band_names.py --get-all"
process = subprocess.Popen(cmd.split(), stdout=subprocess.PIPE)
output, error = process.communicate()
if error:
return error
else:
return output
return "<p>THERE WAS AN ERROR: {0}</p>".format(add_new_band)
@route('/love')