© 2026 LinearBytes Inc.
Search posts, tags, users, and pages
Bijay Shrestha
php python
Great work. I got stock in one thing. How can I make model_name name dynamic so that this function is useable for other model also. Thank for your work.
Sagar Kaurav
Software engineer
you can you instance.__class__.__name__ or you can use User.__name__
instance.__class__.__name__
User.__name__
Thank you Sagar Kaurav. It was very helpful.