Add preferences class