<commit_before>import logging
from django.shortcuts import render, redirect
from django.conf import settings

from findyour3d.users.email_template import send_templated_email
from .forms import ContactForm

logger = logging.getLogger(__name__)


def contact(request):
    context = {}
    feedback_form = ContactForm(request.POST)
    context["form"] = feedback_form
    if request.method == 'POST':
        if feedback_form.is_valid():
            try:
                send_templated_email('Your3d Contact Form: {}'.format(feedback_form.cleaned_data.get('subject')),
                                     'email/contact_form_admin.html',
                                     {'body': feedback_form.cleaned_data.get('body'),
                                      'name': feedback_form.cleaned_data.get('name'),
                                      'subject:': feedback_form.cleaned_data.get('subject')},
                                     [settings.ADMINS])
            except Exception as e:
                logger.exception(str(e))

            feedback_form.save()
            response = redirect('home')
            response['Location'] += '?message_sent=success'
            return response
        else:
            return render(request, 'pages/about.html', context)
    else:
        return render(request, 'pages/about.html', context)<commit_msg>adding comma to recipients in contacts<commit_after>import logging
from django.shortcuts import render, redirect
from django.conf import settings

from findyour3d.users.email_template import send_templated_email
from .forms import ContactForm

logger = logging.getLogger(__name__)


def contact(request):
    context = {}
    feedback_form = ContactForm(request.POST)
    context["form"] = feedback_form
    if request.method == 'POST':
        if feedback_form.is_valid():
            try:
                send_templated_email('Your3d Contact Form: {}'.format(feedback_form.cleaned_data.get('subject')),
                                     'email/contact_form_admin.html',
                                     {'body': feedback_form.cleaned_data.get('body'),
                                      'name': feedback_form.cleaned_data.get('name'),
                                      'subject:': feedback_form.cleaned_data.get('subject')},
                                     [settings.ADMINS, ])
            except Exception as e:
                logger.exception(str(e))

            feedback_form.save()
            response = redirect('home')
            response['Location'] += '?message_sent=success'
            return response
        else:
            return render(request, 'pages/about.html', context)
    else:
        return render(request, 'pages/about.html', context)
{'fraction_non_alphanumeric': 0.10178766873403867, 'fraction_numerical': 0.001459321415541773, 'mean_word_length': 1.9967213114754099, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 10, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3366931', 'n_tokens_mistral': 702, 'n_tokens_neox': 678, 'n_words': 140}