added ability to set timeout per-function