Boundaries and trust decide it. If both are truly platonic and open about it, a sleepover can be harmless.