cleaning up text plugin code and comments