britto
britto copied to clipboard
Migrations
When moving to a new version we need to make sure any change we do doesn't impact old blogs.
So this means upon startup for example we need to check for posts with no publish time and date and add them in.
thats a good idea, maybe every plugin should have a startup function too, checking for its collections to exist and if not doing basically the same as at activate except activating?
That is what the activate method is for, I have called it install now. Upon installing a plugin you will add to the installed collection and also call the plugins install function if it has one. So inside there it can call these types of methods if it is needed.