(a) In all rights of action arising within, or by virtue of, this section and §§ 23-12-501 -- 23-12-504, 23-12-506 and 23-12-507 for personal injury to an employee, or where an injury has resulted in his or her death, the fact that an employee may have been guilty of contributory negligence shall not bar a recovery if the negligence of the employee was of a lesser degree than the negligence of the common carrier, its officers, agents, or employees.
(b) No employee who may be injured or killed shall be held to have been guilty of contributory negligence in any case where the violation by the common carrier or its officials, agents, or employees of any law enacted for the safety of employees or persons contributed to the injury or death of the employee.