Fix compilation issues due to toxcore API changes