(1) Every county or municipal convict shall be comfortably clothed at the expense of the county or municipality, but all clothing furnished shall remain the property of the county or municipality, and shall be thoroughly fumigated and disinfected before being allotted to a convict after having been used by another, and every convict shall be sufficiently fed, to maintain his body and induce his good health, with substantial and suitable food to be furnished and prepared and paid for by the county or municipality. Every convict, for each day’s work he is required to do, shall receive credit on his fine and costs assessed against him at the rate provided under Section 99-19-20, until such fine and costs are fully paid. In case the convict is serving a sentence of imprisonment, each day that he works in serving such sentence shall entitle him credit for equal time on his sentence of imprisonment, but in no instance shall a convict receive credit on the fine and costs and on the time sentenced to imprisonment for the same work. No convict shall be allowed to labor more than eight (8) hours per day, but shall be required, when able, to perform eight (8) hours labor each day.
(2) If a convict is unable to work or if the county or the municipality is unable to provide work for the convict, the convict shall receive the credit provided in Section 99-19-20 for each day of imprisonment.