Warnings

This PR fixes several ruby level warnings.