fixed a bug in inspector