You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jun 13, 2018. It is now read-only.
Both the Package and PackageItem classes have methods to return weight and dimensions in all kinds of units. Moreover, those methods accept options hashes and parameters to modify the return values of those methods.
The latter is bad practice. But now with using measured we can actually remove all of those methods I believe. Replace them with simply weight and other methods for volumetric and dimensional calculations. Then have them return measured objects which understand how to convert to different units by themselves.
Should make the files much much much simpler, and easier to work with.
The text was updated successfully, but these errors were encountered:
These functions are generally useless (I know we don't use it at all, instead opting to manually calculate it external to ActiveShipping), and potentially misleading. I'll start by removing them and re-implement them in a carrier-specific context.
Both the
Package
andPackageItem
classes have methods to return weight and dimensions in all kinds of units. Moreover, those methods accept options hashes and parameters to modify the return values of those methods.The latter is bad practice. But now with using
measured
we can actually remove all of those methods I believe. Replace them with simplyweight
and other methods for volumetric and dimensional calculations. Then have them returnmeasured
objects which understand how to convert to different units by themselves.Should make the files much much much simpler, and easier to work with.
The text was updated successfully, but these errors were encountered: