Skip to content

Update Hash.java#47

Open
mpeters-tha wants to merge 1 commit intoKilianB:masterfrom
mpeters-tha:equalsEdit
Open

Update Hash.java#47
mpeters-tha wants to merge 1 commit intoKilianB:masterfrom
mpeters-tha:equalsEdit

Conversation

@mpeters-tha
Copy link

Changed on equals method to use "instanceof" to check the 2 objects class instead of "obj.getClass()".
This is for when you create a hash using bigInteger contructor which create a Hash object, while if create a hash from an image, the object will be of the hash algorithm type you have chosen, and the equals will return false while the 2 are in fact equals.

@KilianB
Copy link
Owner

KilianB commented Oct 6, 2020

Thanks, I'll have a look at it to see if it breaks identity or importing in any other way

@mpeters-tha
Copy link
Author

Hello,

Do you know if this will be pushed in the master branch ?

Regards,
Matthieu

@KilianB
Copy link
Owner

KilianB commented Oct 21, 2020

I will release a new version this Saturday fixing older issues as well. For a better serialisation it might make sense to also include more class information into the saved state. Next week this issue will be fixed.

@KilianB
Copy link
Owner

KilianB commented Oct 24, 2020

Code is ready, but a few tests still need to be written.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants