added support for other commands and fixed some errors