improve attribute name, fix function name typo