---
title: errorLog()
framework: avfoundation
role: symbol
role_heading: Instance Method
path: avfoundation/avplayeritem/errorlog()
---

# errorLog()

Returns an object that represents a snapshot of the error log.

## Declaration

```swift
nonisolated func errorLog() -> AVPlayerItemErrorLog?
```

## Return Value

Return Value An object that represents a snapshot of the error log. The returned value can be nil.

## Discussion

Discussion If the method returns nil, there is no logging information currently available for the player item.

## See Also

### Accessing logging information

- [accessLog()](avfoundation/avplayeritem/accesslog().md)
- [AVPlayerItemAccessLog](avfoundation/avplayeritemaccesslog.md)
- [AVPlayerItemAccessLogEvent](avfoundation/avplayeritemaccesslogevent.md)
- [AVPlayerItemErrorLog](avfoundation/avplayeritemerrorlog.md)
- [AVPlayerItemErrorLogEvent](avfoundation/avplayeritemerrorlogevent.md)
