Fixed bug, have forgot to pass resource