hopefully fix undeifned bug