Fixed missing at function + added proper stubbing for debug mode