-Fixed a bug with keys sticking between cycles