Nivo slider hide prev/next buttons if there is only one image

<script type=”text/javascript”>
jQuery(function($){
if(jQuery(‘.nivoSlider’).find(‘img’).length>1){
$(‘#slider’).nivoSlider({
effect: ‘fade’ // Specify sets like: ‘fold,fade,sliceDown’
});
}
});
</script>