fixed resource check