updated file with proper syntax to access object