wrote some pretty broken code