Did some performance improvements