minor bug fixes(minor for real this time)