Fixed segfault at unit's priority change

Don't overwrite priority's value by unit's one if it's explicitly set by constructor's argument