bugfix with decode