'Return the parent Extension object using the GET parameter passed
to the view.'

def get_extension_object(self):

    if hasattr(self, 'extension_object'):
        return self.extension_object
    identifier = self.kwargs.get('extension_pk')
    if (not identifier):
        raise ImproperlyConfigured('extension_pk    should    be    passed    to    ExtensionVersionViewSet.')
    try:
        self.extension_object = Extension.objects.without_deleted().by_identifier(identifier)
    except Extension.DoesNotExist:
        raise Http404
    return self.extension_object
