renamed method and improved comments