Small bug fixes

- increased performance