crappy code