Issue #2 fix buildkey method