The Pentagon has reportedly communicated to the White House that it will not allow the U.S. military to be politicized, a move that comes amid a controversy involving a directive to keep the USS John S. McCain out of President Trump's sight during his visit to Japan.

Acting Defense Secretary Patrick Shanahan "directed his chief of staff to speak with the White House military office and reaffirm his mandate that the Department of Defense will not be politicized," Lt. Col. Joe Buccino, a Pentagon spokesman, said in a statement, according to Reuters. "The chief of staff reported that he did reinforce this message."

The Wall Street Journal first reported last week that the White House asked the U.S. Navy to make sure the USS John S. McCain would be "out of sight" while he visited troops stationed in Japan.

"USS John McCain needs to be out of sight," an email outlining the president's plans for the trip read, the Journal reported. "Please confirm #3 will be satisfied."

The order was not implemented after senior Navy officials became aware of the request, Reuters noted.

Trump, who said last week that he was unaware of the request, frequently clashed with the late Sen. John McCain and has kept up his attacks following the Arizona Republican's death.

Shanahan reportedly called on his chief of staff to find out what happened in regard to the request following The Wall Street Journal report.

Shanahan told reporters Sunday that he had no plans of demanding an inspector general investigation, Reuters noted.

"There is no room for politicizing the military," Shanahan said, according to the news service.

Shanahan added that his chief of staff was unaware of the White House request and that a review had not discovered any emails to his team related to the issue.

The White House did not immediately respond to a request for comment from The Hill.