The present disclosure is directed to novel methods of treating type-1 or type-2 diabetes by inactivating TLR2 and TLR4 genes together in cells capable of producing insulin and/or regenerating β cells, and providing the cells to a subject in need thereof.