WCP-157 WCP-158 : Fixed some bugs.