Code Refactoring: made procedure callbacks and table callbacks independant