Nothing contained in Sections 1096 or 1097 shall be construed to make the agent the employer of the workers, or relieve any employer of his obligations to comply with this division, except to the extent that his obligations are discharged by the agent.