Fixed code with removed method.