This method exceed the limit of 15 lines per method need to be refactored