hmm, better debug this properly