bunch redundant code together