some minor changes in function protocol in order to be used in the initCharm.