Made changes based on @alexeyOnGitHub review