partial functions fix