fixed essential bug