Refactor assign command get hash code