Plugin not validating in Logic Pro X 10.2.0

HI I am having an issue with a plugin not validating in Logic but its OK in Reaper and AULab. I can't ind 'DEMO" anywhere I have looked so ar. There are no compiler errors or warnings. (OSX 10.11.2 Xcode 7.2 juce 4.1  Projucer 4.1)

Any help much appreciated 

Message is 

validating Audio Unit DALDistortion by DAL:

    AU Validation Tool
    Version: 1.6.1a1 
    Copyright 2003-2013, Apple Inc. All Rights Reserved.
    Specify -h (-help) for command options

VALIDATING AUDIO UNIT: 'aufx' - 'Ryfz' - 'Manu'
2016-01-21 22:51:15.234 auvaltool[10856:1171087] 22:51:15.233 ERROR:    >audiocomp> 641: Can't register component with 'DEMO' type, subtype, or manufacturer.
Manufacturer String: DAL
AudioUnit Name: DALDistortion
Component Version: 1.0.0 (0x10000)

then a whole lot of tests pass we get to 

Render Test at 64 frames, sample rate: 22050 Hz
Render Test at 137 frames, sample rate: 96000 Hz
Render Test at 4096 frames, sample rate: 48000 Hz
Render Test at 4096 frames, sample rate: 192000 Hz
Render Test at 4096 frames, sample rate: 11025 Hz
Render Test at 512 frames, sample rate: 44100 Hz
1 Channel Test:
Render Test at 512 frames

validation result: crashed validation

Try cleaning your project or trashing the intermediate files (build and DerivedData) and build again. I've had issues with Xcode not updating things and failing in auval (e.g., version numbers must match in a couple of places). It may be that "DEMO" was an old identfier that isn't being updated.

Although the error is that it crashed so the problem might be with your code.

Thanks Martin .. did use those ideas. After much ado I modified getNumPrograms to return 1 instead of 0. The plugin validated in Logic without errors. Jules has made a note somewhere that hosts sometimes have an issue with this being set to 0. Seems this was the reason either directly or indirectly. 

Ah yes, that'd do it. You must return >= 1 from that function.