Any employee who is separated from the service by an undesirable, bad conduct or dishonorable discharge shall not be entitled to any of the benefits of this chapter, except such vested rights as he may have acquired prior thereto by virtue of payments made pursuant to his exercise of option (1) of section 7306 (relating to retirement rights).