modified to fit in public toolkit.
modified to fit in public toolkit.