fixed typescript compile error