Hours after being questioned Tuesday about a violation issued to a building owner over a mural of Democratic presidential candidate Sen. Bernie Sanders, the Philadelphia Department of Licenses and Inspections said it made a mistake.

"The violation was issued in error," Rebecca Swanson, planning director at L&I, said late Tuesday afternoon in response to questions.

"It was political speech, not an advertisement, so no permit was required, so there was no violation," Swanson said.

The developer, Max Glass, received a letter Monday from L&I saying the mural, on the southeast corner of 22nd and Catharine Streets, was not properly permitted.

Glass, 28, who was part of a pro-Sanders group that created the mural, said he considered the mural artwork.

In its letter, L&I referred to the mural as a "painted advertisement," saying it lacked the required permit "and therefore must be removed."

Glass said he planned to apply for a permit and appeal the ruling.

But that became unnecessary after Philly.com learned of the notice and contacted L&I. Staff there said they would look into it.

L&I Commissioner David J. Perri explained the decision in an email.

"The violation notice was issued in error and has been rescinded," Perri wrote. "A permit is not required to paint a mural provided that the mural does not contain commercial advertising and the property is not historic."

The upshot was that the mural could stay.

When told of the reversal late Tuesday, Glass exclaimed: "No way! . . . You just saved me so much time."

The mural was funded by online donations and produced by Glass and photographer Conrad Benner, who blogs under the name Streets Dept. The artists known as Old Broads and Disto took five days to paint it, and finished the project on March 11.

"People have been coming from all over to take photos of it," Glass said of the 67-by-36-foot mural, which shows the senator from Vermont with blue rays shining out from behind him, the Vermont mountains and hills, and a Philadelphia cityscape.

Glass said the mission behind the mural, titled "Philly the Bern," was "to increase the public showing of support for Bernie Sanders for president."

Glass is the majority owner of the building, at 2146 Catharine St., which he is hoping to develop into a mixed-use space with a restaurant and residential units.