fixed typo
improved code style based on automatic code analysis