Minor refactoring.
Fixed warning.