fixed for runtime error but it is only for one procedure :(