fixin the undefined