Cleaned up, removed dead code