Fixed bug in extract command line
Minor bug fixes