Fix reading rules from disk