Use partial with less code