Fixed bugs, exception handling on repository command