- minor bugs corrected