fixed strict standard error and added some docblock