active_module 0.2.1 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: fb059e4cacb00c0531503dbc9994110e4c735ba4e70dd926571998381f8977d4
4
- data.tar.gz: 9182e410141940ad1beccbbb9556cca0fe0b801eaa6f9bb2b461005f59b75f12
3
+ metadata.gz: e84ab7b0e8dd2d33b4eb6dc9ade177bb57361eb23bd62aa774d5e57fab95b831
4
+ data.tar.gz: 02d82ee773888a155453d8765044661bffa180fc0aedf5465a034cc5b34ad03e
5
5
  SHA512:
6
- metadata.gz: 5b11253775eb6a2ddb1d20664784a62f9528ab0213d1670a9c8d31187719106fe27d0eb926f71bd4233da08e817820a52a7dbe74521c58b4b0b6f3d0a3ee19c8
7
- data.tar.gz: 9ddad0a60a5afb1dc3e5b923bac3fb8800aa9af022e2312fbc44928e55a0b5eb5fd0c3b5941ed15d8965f747769fdc9aa280c8446085611131722c2360b2be5c
6
+ metadata.gz: 28f2e81b006c7928e176f8ff91491601fb21ac77223c5096905d703cb54b695ea5e463972d4102f3dd6ca119b2e4df032cfc3531f191d109fd1e6270436d93f9
7
+ data.tar.gz: e06b59e2b248d106e4928cd9d69a6c665d6022d11bba45c258a708b8e4e1a48d7fb29db934fc57ee32f7aaf65491fa6db9aa552c7ccda578b6a7167339e8c05d
data/README.md CHANGED
@@ -1,6 +1,12 @@
1
1
 
2
- # active_module
3
- ![alt text](https://img.shields.io/badge/coverage-100%25-brightgreen)
2
+ # active_module
3
+ [![Gem Version](https://img.shields.io/gem/v/active_module)](https://rubygems.org/gems/active_module)
4
+ [![License: MIT](https://img.shields.io/badge/license-MIT-green.svg)](https://opensource.org/licenses/MIT)
5
+ [![GitHub Actions Workflow Status](https://img.shields.io/github/actions/workflow/status/pedrorolo/active_module/main.yml)](https://github.com/pedrorolo/active_module/blob/main/Rakefile)
6
+ [![100% Coverage](https://img.shields.io/badge/coverage-100%25-brightgreen)](https://github.com/pedrorolo/active_module/blob/main/spec/spec_helper.rb)
7
+ [![Gem Total Downloads](https://img.shields.io/gem/dt/active_module?style=flat)](https://bestgems.org/gems/active_module)
8
+
9
+
4
10
 
5
11
  #### *Modules and Classes as first-class active record values!*
6
12
 
@@ -64,7 +70,7 @@ end
64
70
  Add to your gemfile - and if you are using rails - that's all you need:
65
71
 
66
72
  ```ruby
67
- gem 'active_module', "~> 0.2"
73
+ gem 'active_module', "~> 0.3"
68
74
  ```
69
75
 
70
76
  If you are not using rails, just issue this command after loading active record
@@ -6,6 +6,8 @@ module ActiveModule
6
6
 
7
7
  def call(type_symbol = :active_module)
8
8
  ActiveModel::Type.register(type_symbol, ActiveModule::Base)
9
+ return unless defined?(ActiveRecord::Type)
10
+
9
11
  ActiveRecord::Type.register(type_symbol, ActiveModule::Base)
10
12
  end
11
13
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ActiveModule
4
- VERSION = "0.2.1"
4
+ VERSION = "0.3.0"
5
5
  end
metadata CHANGED
@@ -1,17 +1,17 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_module
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pedro Rolo
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-12-22 00:00:00.000000000 Z
11
+ date: 2024-12-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: activerecord
14
+ name: activemodel
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - "<"