fix for exception: The 'sec' property is read-only