code updates and moved around a few things