slightly messy fixes