Dry-up duplicated code