Fixed a couple bugs + linted.