A federal judge has thrown out a lawsuit by a Dauphin County Prison inmate who claimed his civil rights were violated because he had to eat near a smelly toilet in his cell.

The decision by U.S. Middle District Senior Judge William W. Caldwell came Thursday, less than a week after inmate Jordan S. Herb filed suit.

Records show that Herb, 27, of Harrisburg, was sentenced July 13 by county Judge Scott A. Evans to 1 to 6 months in prison on his guilty pleas to resisting arrest and simple assault charges.

Herb, who represented himself in the suit, claimed he and another inmate had to eat in a cell that was designed for one person. The ammonia smell from the cell’s toilet was so strong it made his eyes water, he contended.

In voiding the suit, Caldwell found that prison officials hadn’t violated Herb’s rights under the Eighth Amendment of the U.S. Constitution, which requires that prisoners receive adequate food, clothing, shelter and medical care.

The toilet in Herb’s cell did work, Caldwell noted. “Albeit distasteful, being required to eat in his cell under such conditions does not amount to an Eighth Amendment deprivation,” the judge found.