fixed a compile time bug