Cleaned up dat code stuff