President Donald Trump says he had nothing to do with directing the U.S. Navy to keep a warship named for the late Sen. John McCain out of sight during his visit to Japan this week.

Trump told reporters as he left the White House on Thursday he "wasn't involved" in the effort. Trump says, "Somebody did it because they thought I didn't like him," but he says he "would never do a thing like that" even though he "wasn't a fan."

The Wall Street Journal first reported Wednesday that a tarp was placed over the warship's name before Trump's arrival and that sailors were instructed to remove any coverings from the ship that included its name.

Trump feuded with McCain publicly for years, continuing his criticism even after the Republican senator from Arizona died last year.