Removing calls to noindex() and wp_no_robots()

Why you are changing the code for these thing which are able done via dashboard.?

WordPress comes with a built-in feature that allows you to instruct search engines not to index your site. All you need to do is visit Settings » Reading and check the box next to Search Engine Visibility option.

When this box is checked, WordPress adds this line to your website’s header:

<meta name="robots" content="noindex,follow" />

WordPress also modifies your site’s robots.txt file and add these lines to it:

User-agent: *
Disallow: /

These lines ask robots (web crawlers) not to index your pages. However, it is totally up to search engines to accept this request or ignore it. Even though most search engines respect this, some page or random image from your site may get indexed.