Application refactoring - split code into multiple methods.