derp this function should only return err