fix failing karma tests