About Getting the First Element from a QuerySet

obj = qs.first() returns the first object in the QuerySet or None if the QuerySet is empty.

Tips and Tricks Programming Django 2.2 Django 1.11 Django 1.8