fixed typescript compiler error