simple case for pattern matching added, clean ups.