Fixed deprecated conditions