Problem with jQuery processing logic

Problem with jQuery processing logic

Hey guys, 
I've got a problem with using jQuery for changing class-attributes of some DOM-Objects.
I've gote some Code like this:
  1. $(document).ready(function () {
  2.       $('#bundles').click( function () {
  3.             $(this).toggleClass('bundlesNegativ', 'bundles');
  4.             [...Some Code that isn't relevant...]
  5.             arrangeNote();
  6.       });
  7.       $('#singles').click( function () {
  8.             $(this).toggleClass('singlesNegativ', 'singles');
  9.             [...Some Code that isn't relevant...]
  10.             arrangeNote();
  11.       });
  12.       $('#purchase').click( function () {
  13.             $(this).toggleClass('bundlesNegativ', 'bundles');
  14.             [...Some Code that isn't relevant...]
  15.             arrangeNote();
  16.       });
  17. });

  1. function arrangeNote() {
  2.       if($('#bundles').attr('class') == 'bundles'
  3.             && $('#singles').attr('class') == 'singles'
  4.             && $('#purchase').attr('class') == 'bundles') {
  5.             showNote(true);
  6.       } else {
  7.             showNote(false);
  8.       }
  9. }

  1. function showNote(isVisible) {
  2.       if(isVisible) {
  3.             $('#noteContainer').show();
  4.             $('#picture').show();
  5.             $('#noteDiv').show();
  6.       } else {
  7.             $('#noteContainer').hide();
  8.             $('#picture').hide();
  9.             $('#noteDiv').hide();
  10.       }
  11. }
My problem is, that the class of the DOM-Object isn't refreshed until I ask for it in the function "arrangeNote".
I don't know how to fix it because I change the class of the Object before I call "arrangeNote". 

Do you have any suggestions?

Best regards 
Tim