[#976] Code cleanup