implement a locale filter and fix implementation of locale property