@emir-hasanbegovic fixed a few small bugs