fix for promices