<commit_before><% if @busy_interval %>
console.log("Created event " + "<%= @busy_interval.id %>")
  $('#calendar').fullCalendar('renderEvent', {
                          id: <%= @busy_interval.id %>,
                          title: 'Busy',
                          start: "<%= @busy_interval.start_time %>",
                          end: "<%= @busy_interval.end_time %>",
                          allDay: true,
                          rendering: "background",
                          color: "red",
                          backgroundColor: "red"
                      }, false );
<% end %>
// TODO: update event rather than render a new event 
// when interval was extended rather than newly created
<commit_msg>fixing display for merged busy intervals<commit_after><% if @busy_interval %>

  // If the event already exists on the calendar, remove it so we can re-render it
  // with the proper start and end
  if ($('#calendar').fullCalendar( 'clientEvents' [<%= @busy_interval.id %>] )) {
    $('#calendar').fullCalendar( 'removeEvents', [<%= @busy_interval.id %>] );
  }
  
  $('#calendar').fullCalendar('renderEvent', {
                          id: <%= @busy_interval.id %>,
                          title: 'Busy',
                          start: "<%= @busy_interval.start_time %>",
                          end: "<%= @busy_interval.end_time %>",
                          allDay: true,
                          rendering: "background",
                          color: "red",
                          backgroundColor: "red"
                      }, false );
<% end %>


{'fraction_non_alphanumeric': 0.14088050314465408, 'fraction_numerical': 0.0, 'mean_word_length': 1.474339035769829, 'pattern_counts': {'":': 0, '<': 16, '<?xml version=': 0, '>': 16, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6936069', 'n_tokens_mistral': 423, 'n_tokens_neox': 402, 'n_words': 97}