# Unified reference detection

**URL:** https://discourse.sourcecred.io/t/unified-reference-detection/301
**Category:** Initiatives
**Tags:** 🏗️in-progress
**Created:** [October 19, 2019, 4:57pm UTC](https://discourse.sourcecred.io/t/unified-reference-detection/301 "2019-10-19T16:57:36Z")
**Posts on this page:** 1
**Showing post:** 4

<div class="post-metadata">

### Author: ![Beanow](https://yyz2.discourse-cdn.com/flex032/user_avatar/discourse.sourcecred.io/beanow/32/98_2.png) [@Beanow](https://discourse.sourcecred.io/u/Beanow)
#### Post date: [December 14, 2019, 6:27pm UTC](https://discourse.sourcecred.io/t/unified-reference-detection/301/4 "2019-12-14T18:27:06Z")

</div>

Had a chat with @decentralion about the API for the unified reference detection and how this should interact with the loading code.

We’ve concluded that the reference detectors should have a dependency on the mirrored data. And the loading code should separate the mirror updating stage from the graph creation stage.

The reference detector would be created as a result from updating the mirror. And a continuation would be provided, which can accept a combination of all reference detectors.

```auto
oldLoad :: () => Promise<Graph>
newLoad :: () => Promise<[
  ReferenceDetector,
  (ReferenceDetector) => Promise<Graph>
]>

```

---

_[View the full topic](https://discourse.sourcecred.io/t/unified-reference-detection/301)._
