[Hopefully] fixed crashing issue; along with some other issues.