Can we get rid of this code?