slightly more optimized