                 Float(centerFrequency), 0)
         }
     }
-    
+
     /// Bandwidth (Cents) ranges from 100 to 12000 (Default: 600)
     public var bandwidth: Double = 600 {
         didSet {
             if bandwidth < 100 {
                 bandwidth = 100
-            }
+            }            
             if bandwidth > 12000 {
                 bandwidth = 12000
             }

/// - parameter bandwidth: Bandwidth (Cents) ranges from 100 to 12000 (Default: 600)
///
public class AKBandPassFilter: AKNode {
    
    private let cd = AudioComponentDescription(
        componentType: kAudioUnitType_Effect,
        componentSubType: kAudioUnitSubType_BandPassFilter,
        componentManufacturer: kAudioUnitManufacturer_Apple,
        componentFlags: 0,
        componentFlagsMask: 0)
    
    internal var internalEffect = AVAudioUnitEffect()
    internal var internalAU = AudioUnit()
    public var avAudioNode: AVAudioNode
    /// Required property for AKNode containing all the node's connections
    public var connectionPoints = [AVAudioConnectionPoint]()
    
    private var input: AKNode?
    
    /// Center Frequency (Hz) ranges from 20 to 22050 (Default: 5000)
    public var centerFrequency: Double = 5000 {
        didSet {
            if centerFrequency < 20 {
                centerFrequency = 20
            }
            if centerFrequency > 22050 {
                centerFrequency = 22050
            }

            self.centerFrequency = centerFrequency
            self.bandwidth = bandwidth
            
            inputGain = AKGain(input, gain: 0)
            mixer = AKMixer(inputGain!)

            internalEffect = AVAudioUnitEffect(audioComponentDescription: cd)
            self.avAudioNode = internalEffect
            AKManager.sharedInstance.engine.attachNode(internalEffect)
            input.addConnectionPoint(self)
            internalAU = internalEffect.audioUnit

            effectGain = AKGain(self, gain: 1)
            mixer.connect(effectGain!)
            self.avAudioNode = mixer.avAudioNode

            AudioUnitSetParameter(internalAU, kBandpassParam_CenterFrequency, kAudioUnitScope_Global, 0, Float(centerFrequency), 0)
            AudioUnitSetParameter(internalAU, kBandpassParam_Bandwidth, kAudioUnitScope_Global, 0, Float(bandwidth), 0)
    }

    /// Function to start, play, or activate the node, all do the same thing
    public func start() {
        if isStopped {
            inputGain?.gain = 0
            effectGain?.gain = 1
            isStarted = true
        }
    }

    /// Function to start, play, or activate the node, all do the same thing
    public func play() {
        start()
    }

    /// Function to stop or bypass the node, both are equivalent
    public func stop() {
        if isPlaying {
            inputGain?.gain = 1
            effectGain?.gain = 0
            isStarted = false
        }
    }

    /// Function to stop or bypass the node, both are equivalent
    public func bypass() {
        stop()
