Remove unnecissary include of pnotes.inc. This file does not use the patient notes...