Skip to content
This repository has been archived by the owner on Aug 11, 2021. It is now read-only.

feat: add util.cid options #11

Merged
merged 3 commits into from
Jun 25, 2018
Merged

feat: add util.cid options #11

merged 3 commits into from
Jun 25, 2018

Conversation

richardschneider
Copy link
Contributor

src/util.js Outdated
* @param {CidCallback} callback - Callback that handles the return value
* @returns {void}
*/
const cid = (dagNode, callback) => {
const cid = (dagNode, options, callback) => {
if (options instanceof Function) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Searching through the existing IPFS/IPLD code base it seems that the preferred way for checking if something is a function is: if (typeof options !== 'function') {. My guess is that it is related to code minifiers. Please change it.

@coveralls
Copy link

coveralls commented Jun 24, 2018

Pull Request Test Coverage Report for Build 22

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 100.0%

Totals Coverage Status
Change from base Build 19: 0.0%
Covered Lines: 84
Relevant Lines: 84

💛 - Coveralls

Copy link
Member

@vmx vmx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When you merge, please do a "squash merge" and use the commit message of the first commit. That gives a clean Git history.

@richardschneider richardschneider merged commit 8384849 into master Jun 25, 2018
@richardschneider richardschneider removed the status/in-progress In progress label Jun 25, 2018
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants