Added bug fixes.