In all cases when the leased premises are sublet, or the lease is assigned, the landlord shall have the same right to enforce his or her lien against the sublessee or assignee, that the landlord has against the tenant to whom the premises were leased.
735 ILCS 5/9-317