I am setting up a child theme for some of my faculty members, and as a part of the theme, I would like a handful of plugins to be activated at the time that the theme is activated. So, naturally, I used the after_setup_theme action and called my setup function. It works great, except it runs on EVERY request (admin and otherwise). I proved this by adding this to the end of the setup function:
So the question is, is this a bug? Am I somehow doing something wrong? Here is the complete code that I am using:
Any insight would be much appreciated!