bitcoin-spv - unnecessary logic in BytesLib.toBytes32()
The heavily used library function `BytesLib.toBytes32()` unnecessarily casts `_source` to `bytes` (same type) and creates a copy of the dynamic byte array to check it's length, while this can be done directly on the user-provided `bytes` `_source`.\\n```\\nfunction toBytes32(bytes memory \\_source) pure internal returns (bytes32 result) {\\n    bytes memory tempEmptyStringTest = bytes(\\_source);\\n    if (tempEmptyStringTest.length == 0) {\\n        return 0x0;\\n    }\\n\\n    assembly {\\n        result := mload(add(\\_source, 32))\\n    }\\n}\\n```\\n
```\\nfunction toBytes32(bytes memory \\_source) pure internal returns (bytes32 result) {\\n        if (\\_source.length == 0) {\\n            return 0x0;\\n        }\\n\\n        assembly {\\n            result := mload(add(\\_source, 32))\\n        }\\n    }\\n```\\n
```\\nfunction toBytes32(bytes memory \\_source) pure internal returns (bytes32 result) {\\n    bytes memory tempEmptyStringTest = bytes(\\_source);\\n    if (tempEmptyStringTest.length == 0) {\\n        return 0x0;\\n    }\\n\\n    assembly {\\n        result := mload(add(\\_source, 32))\\n    }\\n}\\n```\\n