Small bugs fixed