fixed bug

trying to draw invalid skeleton caused runtime error