Another hotfix

A fix for the function that can't return value in write context.