removes superfluous prepare statement + refactors