dioscouri / library

5 stars 3 forks source link

Make all component entrypoints check for DSC Library, and if not found, they should fail NICELY, with an error message with instructions, not with a Fatal Error #9

Open ChrisFrench opened 12 years ago

ChrisFrench commented 12 years ago

This was something we brought up while Migrating Billets and something we should probably decide on the best approach and Handle.

How do we want to handle doing this?

rdiaztushman commented 11 years ago

In fact, each component's plugins and modules should do the same. It's probably easiest to check for a defined constant, something like:

if (!defined('_DSC')) { return; }

I'm using return; rather than exit; so that the module/plugin/component simply doesn't execute rather than causing a fatal error or halting the application.

ChrisFrench commented 11 years ago

sounds good, I will apply these to tienda and other projects