<commit_before><h1>Signup for Acme Projects</h1>

<% if @call && !@call.errors.empty? %>
<div class="errors">
  <p><strong>Could not complete signup. Please correct the following problems:</strong></p>
  <ul>
    <% @call.errors.each do |error| %>
    <li><%= error.message %></li>
    <% end %>
  </ul>
</div>
<% end %>

<% if @flash %>
<div class="errors">
  <p><strong><%= @flash %></strong></p>
</div>
<% end %>

<form method="post" action="<%= chargify.base_uri %>/signups">
  <%= chargify.direct.secure_parameters(
    :data => {
      :redirect_uri => "http://localhost:4567/verify"
    }
  ).to_form_inputs %>
  <fieldset>
    <legend>Select Plan</legend>
    <p>
      <input type="radio" name="signup[product][handle]" id="signup_product_handle_basic" value="basic" <%= 'checked' if original_params.signup.product.handle == 'basic' %>/><label>Basic</label>
    </p>
    <p>
      <input type="radio" name="signup[product][handle]" id="signup_product_handle_pro" value="pro" <%= 'checked' if original_params.signup.product.handle == 'pro' %>/><label>Pro</label>
    </p>
  </fieldset>
  
  <fieldset>
    <legend>About You</legend>

    <p>
      <label for="signup_customer_first_name">First Name</label><br/>
      <input type="text" name="signup[customer][first_name]" id="signup_customer_first_name" value="<%= h(original_params.signup.customer.first_name) %>" />
    </p>
    <p>
      <label for="signup_customer_last_name">Last Name</label><br/>
      <input type="text" name="signup[customer][last_name]" id="signup_customer_last_name" value="<%= h(original_params.signup.customer.last_name) %>"/>
    </p>
    <p>
      <label for="signup_customer_email">Email</label><br/>
      <input type="text" name="signup[customer][email]" id="signup_customer_email" value="<%= h(original_params.signup.customer.email) %>"/>
    </p>
  </fieldset>
  
  <fieldset>
    <legend>Payment Profile</legend>

    <p>
      <label for="signup_payment_profile_first_name">First Name on Card</label><br/>
      <input type="text" name="signup[payment_profile][first_name]" id="signup_payment_profile_first_name" value="<%= h(original_params.signup.payment_profile.first_name) %>" />
    </p>
    
    <p>
      <label for="signup_payment_profile_first_name">Last Name on Card</label><br/>
      <input type="text" name="signup[payment_profile][last_name]" id="signup_payment_profile_last_name" value="<%= h(original_params.signup.payment_profile.last_name) %>" />
    </p>
    
    <p>
      <label for="signup_payment_profile_card_number">Card Number</label><br/>
      <input type="text" name="signup[payment_profile][card_number]" id="signup_payment_profile_card_number" value="<%= h(original_params.signup.payment_profile.card_number) %>" />
    </p>
    
    <p>
      Expiration <label for="signup_payment_profile_expiration_month">Month</label> / <label for="signup_payment_profile_expiration_year">Year</label><br/>
      <select name="signup[payment_profile][expiration_month]" id="signup_payment_profile_expiration_month">
        <% for i in 1..12 do %>
        <option value="<%= i %>"<%= ' selected' if original_params.signup.payment_profile.expiration_month == i.to_s %>><%= "%02d" % i.to_s %></option>
        <% end %>
      </select>
      /
      <select name="signup[payment_profile][expiration_year]" id="signup_payment_profile_expiration_year">
        <% t = Time.now.year; for i in t..(t+10) %>
        <option value="<%= i %>"<%= ' selected' if original_params.signup.payment_profile.expiration_year == i.to_s %>><%= i %></option>
        <% end %>
      </select>
    </p>
  </fieldset><commit_msg>Display unset params as blank in the form, not as "{}"<commit_after><h1>Signup for Acme Projects</h1>

<% if @call && !@call.errors.empty? %>
<div class="errors">
  <p><strong>Could not complete signup. Please correct the following problems:</strong></p>
  <ul>
    <% @call.errors.each do |error| %>
    <li><%= error.message %></li>
    <% end %>
  </ul>
</div>
<% end %>

<% if @flash %>
<div class="errors">
  <p><strong><%= @flash %></strong></p>
</div>
<% end %>

<form method="post" action="<%= chargify.base_uri %>/signups">
  <%= chargify.direct.secure_parameters(
    :data => {
      :redirect_uri => "http://localhost:4567/verify"
    }
  ).to_form_inputs %>
  <fieldset>
    <legend>Select Plan</legend>
    <p>
      <input type="radio" name="signup[product][handle]" id="signup_product_handle_basic" value="basic" <%= 'checked' if original_params.signup.product[:handle] == 'basic' %>/><label>Basic</label>
    </p>
    <p>
      <input type="radio" name="signup[product][handle]" id="signup_product_handle_pro" value="pro" <%= 'checked' if original_params.signup.product[:handle] == 'pro' %>/><label>Pro</label>
    </p>
  </fieldset>
  
  <fieldset>
    <legend>About You</legend>

    <p>
      <label for="signup_customer_first_name">First Name</label><br/>
      <input type="text" name="signup[customer][first_name]" id="signup_customer_first_name" value="<%= h(original_params.signup.customer[:first_name]) %>" />
    </p>
    <p>
      <label for="signup_customer_last_name">Last Name</label><br/>
      <input type="text" name="signup[customer][last_name]" id="signup_customer_last_name" value="<%= h(original_params.signup.customer[:last_name]) %>"/>
    </p>
    <p>
      <label for="signup_customer_email">Email</label><br/>
      <input type="text" name="signup[customer][email]" id="signup_customer_email" value="<%= h(original_params.signup.customer[:email]) %>"/>
    </p>
  </fieldset>
  
  <fieldset>
    <legend>Payment Profile</legend>

    <p>
      <label for="signup_payment_profile_first_name">First Name on Card</label><br/>
      <input type="text" name="signup[payment_profile][first_name]" id="signup_payment_profile_first_name" value="<%= h(original_params.signup.payment_profile[:first_name]) %>" />
    </p>
    
    <p>
      <label for="signup_payment_profile_first_name">Last Name on Card</label><br/>
      <input type="text" name="signup[payment_profile][last_name]" id="signup_payment_profile_last_name" value="<%= h(original_params.signup.payment_profile[:last_name]) %>" />
    </p>
    
    <p>
      <label for="signup_payment_profile_card_number">Card Number</label><br/>
      <input type="text" name="signup[payment_profile][card_number]" id="signup_payment_profile_card_number" value="<%= h(original_params.signup.payment_profile[:card_number]) %>" />
    </p>
    
    <p>
      Expiration <label for="signup_payment_profile_expiration_month">Month</label> / <label for="signup_payment_profile_expiration_year">Year</label><br/>
      <select name="signup[payment_profile][expiration_month]" id="signup_payment_profile_expiration_month">
        <% for i in 1..12 do %>
        <option value="<%= i %>"<%= ' selected' if original_params.signup.payment_profile[:expiration_month] == i.to_s %>><%= "%02d" % i.to_s %></option>
        <% end %>
      </select>
      /
      <select name="signup[payment_profile][expiration_year]" id="signup_payment_profile_expiration_year">
        <% t = Time.now.year; for i in t..(t+10) %>
        <option value="<%= i %>"<%= ' selected' if original_params.signup.payment_profile[:expiration_year] == i.to_s %>><%= i %></option>
        <% end %>
      </select>
    </p>
  </fieldset>
{'fraction_non_alphanumeric': 0.1901958099411201, 'fraction_numerical': 0.003560180747637957, 'mean_word_length': 4.304284676833697, 'pattern_counts': {'":': 0, '<': 243, '<?xml version=': 0, '>': 247, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2594976', 'n_tokens_mistral': 2643, 'n_tokens_neox': 2502, 'n_words': 409}