Streamlined some code.