def _find_certificate_metadata(self, uid=None):
        """
        Find certificate by certificate uid
        :param uid: certificate uid
        :return: certificate from certificates collection
        """
        certificate = self.db.certificates.find_one({'uid': uid})
        return certificate