Fix detect syntax