Minor speedups :), was easy to implement so did it.