@warp-drive/legacy 5.8.0-alpha.37 → 5.8.0-alpha.40

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.
Files changed (433) hide show
  1. package/dist/unpkg/{prod-deprecated/-private-B1pSSN52.js → dev/-private-DbaSCSym.js} +65 -70
  2. package/dist/unpkg/dev/adapter/-private.js +1 -1
  3. package/dist/unpkg/dev/adapter/error.js +2 -3
  4. package/dist/unpkg/dev/adapter/json-api.js +144 -5
  5. package/dist/unpkg/dev/adapter/rest.js +15 -17
  6. package/dist/unpkg/dev/adapter.js +9 -10
  7. package/dist/unpkg/dev/compat/-private.js +1 -1
  8. package/dist/unpkg/dev/compat/builders.js +30 -28
  9. package/dist/unpkg/dev/compat/extensions.js +4 -5
  10. package/dist/unpkg/dev/compat/utils.js +2 -3
  11. package/dist/unpkg/dev/compat.js +226 -100
  12. package/dist/unpkg/{dev-deprecated/errors-CIGPcDvd.js → dev/errors-DD96TBEs.js} +78 -82
  13. package/dist/unpkg/{dev-deprecated/hooks-QqRnX108.js → dev/hooks-CqWjNWeL.js} +14 -15
  14. package/dist/unpkg/dev/index.js +23 -21
  15. package/dist/unpkg/dev/{json-BNrV8EYG.js → json-CCU-ZQ4b.js} +6 -9
  16. package/dist/unpkg/dev/model/-private.js +1 -1
  17. package/dist/unpkg/dev/model/migration-support.js +6 -34
  18. package/dist/unpkg/dev/model.js +57 -46
  19. package/dist/unpkg/{dev-deprecated/schema-provider-g5MfTj8n.js → dev/schema-provider-B8jiJOYC.js} +113 -222
  20. package/dist/unpkg/{prod/serialize-into-hash-BnYvPex3.js → dev/serialize-into-hash-CPAZXrQU.js} +16 -18
  21. package/dist/unpkg/dev/serializer/json-api.js +140 -19
  22. package/dist/unpkg/dev/serializer/json.js +1 -3
  23. package/dist/unpkg/dev/serializer/rest.js +12 -13
  24. package/dist/unpkg/dev/store.js +55 -55
  25. package/dist/unpkg/dev/util-DvanW33H.js +20 -0
  26. package/dist/unpkg/dev/utils-BhvS1iTS.js +8 -0
  27. package/dist/unpkg/dev-deprecated/{-private-B1pSSN52.js → -private-DbaSCSym.js} +65 -70
  28. package/dist/unpkg/dev-deprecated/adapter/-private.js +1 -1
  29. package/dist/unpkg/dev-deprecated/adapter/error.js +2 -3
  30. package/dist/unpkg/dev-deprecated/adapter/json-api.js +144 -5
  31. package/dist/unpkg/dev-deprecated/adapter/rest.js +15 -17
  32. package/dist/unpkg/dev-deprecated/adapter.js +9 -10
  33. package/dist/unpkg/dev-deprecated/compat/-private.js +1 -1
  34. package/dist/unpkg/dev-deprecated/compat/builders.js +30 -28
  35. package/dist/unpkg/dev-deprecated/compat/extensions.js +4 -5
  36. package/dist/unpkg/dev-deprecated/compat/utils.js +2 -3
  37. package/dist/unpkg/dev-deprecated/compat.js +226 -100
  38. package/dist/unpkg/{dev/errors-CIGPcDvd.js → dev-deprecated/errors-DEnabIZj.js} +78 -79
  39. package/dist/unpkg/{prod-deprecated/hooks-QqRnX108.js → dev-deprecated/hooks-CAll-Ets.js} +14 -15
  40. package/dist/unpkg/dev-deprecated/index.js +22 -21
  41. package/dist/unpkg/{prod-deprecated/json-BNrV8EYG.js → dev-deprecated/json-CCU-ZQ4b.js} +6 -9
  42. package/dist/unpkg/dev-deprecated/model/-private.js +1 -1
  43. package/dist/unpkg/dev-deprecated/model/migration-support.js +7 -18
  44. package/dist/unpkg/dev-deprecated/model.js +58 -43
  45. package/dist/unpkg/{prod-deprecated/schema-provider-g5MfTj8n.js → dev-deprecated/schema-provider-k2qXQTBg.js} +114 -198
  46. package/dist/unpkg/{prod-deprecated/serialize-into-hash-BnYvPex3.js → dev-deprecated/serialize-into-hash-CPAZXrQU.js} +16 -18
  47. package/dist/unpkg/dev-deprecated/serializer/json-api.js +140 -19
  48. package/dist/unpkg/dev-deprecated/serializer/json.js +1 -3
  49. package/dist/unpkg/dev-deprecated/serializer/rest.js +12 -13
  50. package/dist/unpkg/dev-deprecated/store.js +55 -55
  51. package/dist/unpkg/{prod-deprecated/util-Dul6TZts.js → dev-deprecated/util-CWr5WQOT.js} +2 -13
  52. package/dist/unpkg/dev-deprecated/utils-C9PJehtL.js +12 -0
  53. package/dist/unpkg/prod/{-private-B1pSSN52.js → -private-Cvf_97EG.js} +6 -246
  54. package/dist/unpkg/prod/adapter/-private.js +1 -1
  55. package/dist/unpkg/prod/adapter/error.js +0 -6
  56. package/dist/unpkg/prod/adapter/json-api.js +142 -8
  57. package/dist/unpkg/prod/adapter/rest.js +1 -40
  58. package/dist/unpkg/prod/adapter.js +7 -41
  59. package/dist/unpkg/prod/compat/-private.js +1 -1
  60. package/dist/unpkg/prod/compat/builders.js +4 -67
  61. package/dist/unpkg/prod/compat/extensions.js +0 -11
  62. package/dist/unpkg/prod/compat/utils.js +0 -6
  63. package/dist/unpkg/prod/compat.js +13 -307
  64. package/dist/unpkg/prod/{errors-CIGPcDvd.js → errors-CXnfnBfQ.js} +4 -256
  65. package/dist/unpkg/prod/hooks-DvyWhLNg.js +41 -0
  66. package/dist/unpkg/prod/index.js +9 -53
  67. package/dist/unpkg/prod/{json-BNrV8EYG.js → json-BYrUP8ao.js} +0 -16
  68. package/dist/unpkg/prod/model/-private.js +1 -1
  69. package/dist/unpkg/prod/model/migration-support.js +3 -38
  70. package/dist/unpkg/prod/model.js +31 -105
  71. package/dist/unpkg/{dev/schema-provider-g5MfTj8n.js → prod/schema-provider-CHujJvA9.js} +20 -454
  72. package/dist/unpkg/{dev-deprecated/serialize-into-hash-BnYvPex3.js → prod/serialize-into-hash-DYU2egXl.js} +1 -47
  73. package/dist/unpkg/prod/serializer/json-api.js +124 -60
  74. package/dist/unpkg/prod/serializer/json.js +1 -3
  75. package/dist/unpkg/prod/serializer/rest.js +2 -35
  76. package/dist/unpkg/prod/store.js +4 -136
  77. package/dist/unpkg/prod/util-DvanW33H.js +20 -0
  78. package/dist/unpkg/prod/utils-BhvS1iTS.js +8 -0
  79. package/dist/unpkg/{dev/-private-B1pSSN52.js → prod-deprecated/-private-Cvf_97EG.js} +6 -246
  80. package/dist/unpkg/prod-deprecated/adapter/-private.js +1 -1
  81. package/dist/unpkg/prod-deprecated/adapter/error.js +0 -6
  82. package/dist/unpkg/prod-deprecated/adapter/json-api.js +142 -8
  83. package/dist/unpkg/prod-deprecated/adapter/rest.js +1 -40
  84. package/dist/unpkg/prod-deprecated/adapter.js +7 -41
  85. package/dist/unpkg/prod-deprecated/compat/-private.js +1 -1
  86. package/dist/unpkg/prod-deprecated/compat/builders.js +4 -67
  87. package/dist/unpkg/prod-deprecated/compat/extensions.js +0 -11
  88. package/dist/unpkg/prod-deprecated/compat/utils.js +0 -6
  89. package/dist/unpkg/prod-deprecated/compat.js +13 -307
  90. package/dist/unpkg/prod-deprecated/{errors-CIGPcDvd.js → errors-CG1SPYVg.js} +4 -253
  91. package/dist/unpkg/prod-deprecated/hooks-BIUBiNGR.js +41 -0
  92. package/dist/unpkg/prod-deprecated/index.js +8 -53
  93. package/dist/unpkg/{dev-deprecated/json-BNrV8EYG.js → prod-deprecated/json-BYrUP8ao.js} +0 -16
  94. package/dist/unpkg/prod-deprecated/model/-private.js +1 -1
  95. package/dist/unpkg/prod-deprecated/model/migration-support.js +4 -22
  96. package/dist/unpkg/prod-deprecated/model.js +31 -102
  97. package/dist/unpkg/{prod/schema-provider-g5MfTj8n.js → prod-deprecated/schema-provider-BJ4TWnZf.js} +21 -412
  98. package/dist/unpkg/{dev/serialize-into-hash-BnYvPex3.js → prod-deprecated/serialize-into-hash-DYU2egXl.js} +1 -47
  99. package/dist/unpkg/prod-deprecated/serializer/json-api.js +124 -60
  100. package/dist/unpkg/prod-deprecated/serializer/json.js +1 -3
  101. package/dist/unpkg/prod-deprecated/serializer/rest.js +2 -35
  102. package/dist/unpkg/prod-deprecated/store.js +4 -136
  103. package/dist/unpkg/{dev/util-Dul6TZts.js → prod-deprecated/util-B6cn-i93.js} +1 -13
  104. package/dist/unpkg/prod-deprecated/utils-BUWwQwCh.js +11 -0
  105. package/package.json +14 -22
  106. package/dist/unpkg/dev/declarations/adapter/-private/build-url-mixin.d.ts +0 -33
  107. package/dist/unpkg/dev/declarations/adapter/-private/fastboot-interface.d.ts +0 -8
  108. package/dist/unpkg/dev/declarations/adapter/-private/utils/continue-on-reject.d.ts +0 -1
  109. package/dist/unpkg/dev/declarations/adapter/-private/utils/determine-body-promise.d.ts +0 -4
  110. package/dist/unpkg/dev/declarations/adapter/-private/utils/fetch.d.ts +0 -8
  111. package/dist/unpkg/dev/declarations/adapter/-private/utils/parse-response-headers.d.ts +0 -1
  112. package/dist/unpkg/dev/declarations/adapter/-private/utils/serialize-into-hash.d.ts +0 -6
  113. package/dist/unpkg/dev/declarations/adapter/-private/utils/serialize-query-params.d.ts +0 -5
  114. package/dist/unpkg/dev/declarations/adapter/-private.d.ts +0 -5
  115. package/dist/unpkg/dev/declarations/adapter/error.d.ts +0 -215
  116. package/dist/unpkg/dev/declarations/adapter/json-api.d.ts +0 -231
  117. package/dist/unpkg/dev/declarations/adapter/rest.d.ts +0 -815
  118. package/dist/unpkg/dev/declarations/adapter.d.ts +0 -770
  119. package/dist/unpkg/dev/declarations/compat/-private.d.ts +0 -13
  120. package/dist/unpkg/dev/declarations/compat/builders/find-all.d.ts +0 -35
  121. package/dist/unpkg/dev/declarations/compat/builders/find-record.d.ts +0 -56
  122. package/dist/unpkg/dev/declarations/compat/builders/query.d.ts +0 -66
  123. package/dist/unpkg/dev/declarations/compat/builders/save-record.d.ts +0 -34
  124. package/dist/unpkg/dev/declarations/compat/builders/utils.d.ts +0 -3
  125. package/dist/unpkg/dev/declarations/compat/builders.d.ts +0 -14
  126. package/dist/unpkg/dev/declarations/compat/extensions.d.ts +0 -59
  127. package/dist/unpkg/dev/declarations/compat/legacy-network-handler/fetch-manager.d.ts +0 -55
  128. package/dist/unpkg/dev/declarations/compat/legacy-network-handler/identifier-has-id.d.ts +0 -2
  129. package/dist/unpkg/dev/declarations/compat/legacy-network-handler/legacy-data-fetch.d.ts +0 -11
  130. package/dist/unpkg/dev/declarations/compat/legacy-network-handler/legacy-data-utils.d.ts +0 -5
  131. package/dist/unpkg/dev/declarations/compat/legacy-network-handler/legacy-network-handler.d.ts +0 -2
  132. package/dist/unpkg/dev/declarations/compat/legacy-network-handler/minimum-adapter-interface.d.ts +0 -524
  133. package/dist/unpkg/dev/declarations/compat/legacy-network-handler/minimum-serializer-interface.d.ts +0 -213
  134. package/dist/unpkg/dev/declarations/compat/legacy-network-handler/serializer-response.d.ts +0 -6
  135. package/dist/unpkg/dev/declarations/compat/legacy-network-handler/snapshot-record-array.d.ts +0 -110
  136. package/dist/unpkg/dev/declarations/compat/legacy-network-handler/snapshot.d.ts +0 -255
  137. package/dist/unpkg/dev/declarations/compat/utils.d.ts +0 -137
  138. package/dist/unpkg/dev/declarations/compat.d.ts +0 -157
  139. package/dist/unpkg/dev/declarations/index.d.ts +0 -70
  140. package/dist/unpkg/dev/declarations/model/-private/attr.d.ts +0 -170
  141. package/dist/unpkg/dev/declarations/model/-private/belongs-to.d.ts +0 -174
  142. package/dist/unpkg/dev/declarations/model/-private/debug/assert-polymorphic-type.d.ts +0 -5
  143. package/dist/unpkg/dev/declarations/model/-private/errors.d.ts +0 -289
  144. package/dist/unpkg/dev/declarations/model/-private/has-many.d.ts +0 -162
  145. package/dist/unpkg/dev/declarations/model/-private/hooks.d.ts +0 -10
  146. package/dist/unpkg/dev/declarations/model/-private/legacy-relationships-support.d.ts +0 -47
  147. package/dist/unpkg/dev/declarations/model/-private/model-for-mixin.d.ts +0 -3
  148. package/dist/unpkg/dev/declarations/model/-private/model-methods.d.ts +0 -39
  149. package/dist/unpkg/dev/declarations/model/-private/model.d.ts +0 -1269
  150. package/dist/unpkg/dev/declarations/model/-private/notify-changes.d.ts +0 -4
  151. package/dist/unpkg/dev/declarations/model/-private/promise-belongs-to.d.ts +0 -40
  152. package/dist/unpkg/dev/declarations/model/-private/promise-many-array.d.ts +0 -124
  153. package/dist/unpkg/dev/declarations/model/-private/record-state.d.ts +0 -58
  154. package/dist/unpkg/dev/declarations/model/-private/references/belongs-to.d.ts +0 -498
  155. package/dist/unpkg/dev/declarations/model/-private/references/has-many.d.ts +0 -500
  156. package/dist/unpkg/dev/declarations/model/-private/schema-provider.d.ts +0 -56
  157. package/dist/unpkg/dev/declarations/model/-private/type-utils.d.ts +0 -57
  158. package/dist/unpkg/dev/declarations/model/-private/util.d.ts +0 -5
  159. package/dist/unpkg/dev/declarations/model/-private.d.ts +0 -8
  160. package/dist/unpkg/dev/declarations/model/migration-support.d.ts +0 -280
  161. package/dist/unpkg/dev/declarations/model-fragments/extensions/fragment-array.d.ts +0 -16
  162. package/dist/unpkg/dev/declarations/model-fragments/extensions/fragment.d.ts +0 -15
  163. package/dist/unpkg/dev/declarations/model-fragments/hooks/model-for.d.ts +0 -20
  164. package/dist/unpkg/dev/declarations/model-fragments/index.d.ts +0 -5
  165. package/dist/unpkg/dev/declarations/model-fragments/instance-initializers/fragment-extensions.d.ts +0 -9
  166. package/dist/unpkg/dev/declarations/model-fragments/utilities/with-array-defaults.d.ts +0 -15
  167. package/dist/unpkg/dev/declarations/model-fragments/utilities/with-fragment-array-defaults.d.ts +0 -20
  168. package/dist/unpkg/dev/declarations/model-fragments/utilities/with-fragment-defaults.d.ts +0 -19
  169. package/dist/unpkg/dev/declarations/model-fragments/utilities/with-legacy.d.ts +0 -3
  170. package/dist/unpkg/dev/declarations/model-fragments.d.ts +0 -9
  171. package/dist/unpkg/dev/declarations/model.d.ts +0 -49
  172. package/dist/unpkg/dev/declarations/serializer/-private/embedded-records-mixin.d.ts +0 -91
  173. package/dist/unpkg/dev/declarations/serializer/-private/transforms/boolean.d.ts +0 -47
  174. package/dist/unpkg/dev/declarations/serializer/-private/transforms/date.d.ts +0 -28
  175. package/dist/unpkg/dev/declarations/serializer/-private/transforms/number.d.ts +0 -29
  176. package/dist/unpkg/dev/declarations/serializer/-private/transforms/string.d.ts +0 -29
  177. package/dist/unpkg/dev/declarations/serializer/-private/transforms/transform.d.ts +0 -118
  178. package/dist/unpkg/dev/declarations/serializer/-private/utils.d.ts +0 -3
  179. package/dist/unpkg/dev/declarations/serializer/json-api.d.ts +0 -123
  180. package/dist/unpkg/dev/declarations/serializer/json.d.ts +0 -75
  181. package/dist/unpkg/dev/declarations/serializer/rest.d.ts +0 -51
  182. package/dist/unpkg/dev/declarations/serializer/transform.d.ts +0 -5
  183. package/dist/unpkg/dev/declarations/serializer.d.ts +0 -254
  184. package/dist/unpkg/dev/declarations/store/-private.d.ts +0 -223
  185. package/dist/unpkg/dev/declarations/store.d.ts +0 -3
  186. package/dist/unpkg/dev/hooks-QqRnX108.js +0 -74
  187. package/dist/unpkg/dev/utils-Cqw9eRj5.js +0 -23
  188. package/dist/unpkg/dev-deprecated/declarations/adapter/-private/build-url-mixin.d.ts +0 -33
  189. package/dist/unpkg/dev-deprecated/declarations/adapter/-private/fastboot-interface.d.ts +0 -8
  190. package/dist/unpkg/dev-deprecated/declarations/adapter/-private/utils/continue-on-reject.d.ts +0 -1
  191. package/dist/unpkg/dev-deprecated/declarations/adapter/-private/utils/determine-body-promise.d.ts +0 -4
  192. package/dist/unpkg/dev-deprecated/declarations/adapter/-private/utils/fetch.d.ts +0 -8
  193. package/dist/unpkg/dev-deprecated/declarations/adapter/-private/utils/parse-response-headers.d.ts +0 -1
  194. package/dist/unpkg/dev-deprecated/declarations/adapter/-private/utils/serialize-into-hash.d.ts +0 -6
  195. package/dist/unpkg/dev-deprecated/declarations/adapter/-private/utils/serialize-query-params.d.ts +0 -5
  196. package/dist/unpkg/dev-deprecated/declarations/adapter/-private.d.ts +0 -5
  197. package/dist/unpkg/dev-deprecated/declarations/adapter/error.d.ts +0 -215
  198. package/dist/unpkg/dev-deprecated/declarations/adapter/json-api.d.ts +0 -231
  199. package/dist/unpkg/dev-deprecated/declarations/adapter/rest.d.ts +0 -815
  200. package/dist/unpkg/dev-deprecated/declarations/adapter.d.ts +0 -770
  201. package/dist/unpkg/dev-deprecated/declarations/compat/-private.d.ts +0 -13
  202. package/dist/unpkg/dev-deprecated/declarations/compat/builders/find-all.d.ts +0 -35
  203. package/dist/unpkg/dev-deprecated/declarations/compat/builders/find-record.d.ts +0 -56
  204. package/dist/unpkg/dev-deprecated/declarations/compat/builders/query.d.ts +0 -66
  205. package/dist/unpkg/dev-deprecated/declarations/compat/builders/save-record.d.ts +0 -34
  206. package/dist/unpkg/dev-deprecated/declarations/compat/builders/utils.d.ts +0 -3
  207. package/dist/unpkg/dev-deprecated/declarations/compat/builders.d.ts +0 -14
  208. package/dist/unpkg/dev-deprecated/declarations/compat/extensions.d.ts +0 -59
  209. package/dist/unpkg/dev-deprecated/declarations/compat/legacy-network-handler/fetch-manager.d.ts +0 -55
  210. package/dist/unpkg/dev-deprecated/declarations/compat/legacy-network-handler/identifier-has-id.d.ts +0 -2
  211. package/dist/unpkg/dev-deprecated/declarations/compat/legacy-network-handler/legacy-data-fetch.d.ts +0 -11
  212. package/dist/unpkg/dev-deprecated/declarations/compat/legacy-network-handler/legacy-data-utils.d.ts +0 -5
  213. package/dist/unpkg/dev-deprecated/declarations/compat/legacy-network-handler/legacy-network-handler.d.ts +0 -2
  214. package/dist/unpkg/dev-deprecated/declarations/compat/legacy-network-handler/minimum-adapter-interface.d.ts +0 -524
  215. package/dist/unpkg/dev-deprecated/declarations/compat/legacy-network-handler/minimum-serializer-interface.d.ts +0 -213
  216. package/dist/unpkg/dev-deprecated/declarations/compat/legacy-network-handler/serializer-response.d.ts +0 -6
  217. package/dist/unpkg/dev-deprecated/declarations/compat/legacy-network-handler/snapshot-record-array.d.ts +0 -110
  218. package/dist/unpkg/dev-deprecated/declarations/compat/legacy-network-handler/snapshot.d.ts +0 -255
  219. package/dist/unpkg/dev-deprecated/declarations/compat/utils.d.ts +0 -137
  220. package/dist/unpkg/dev-deprecated/declarations/compat.d.ts +0 -157
  221. package/dist/unpkg/dev-deprecated/declarations/index.d.ts +0 -70
  222. package/dist/unpkg/dev-deprecated/declarations/model/-private/attr.d.ts +0 -170
  223. package/dist/unpkg/dev-deprecated/declarations/model/-private/belongs-to.d.ts +0 -174
  224. package/dist/unpkg/dev-deprecated/declarations/model/-private/debug/assert-polymorphic-type.d.ts +0 -5
  225. package/dist/unpkg/dev-deprecated/declarations/model/-private/errors.d.ts +0 -289
  226. package/dist/unpkg/dev-deprecated/declarations/model/-private/has-many.d.ts +0 -162
  227. package/dist/unpkg/dev-deprecated/declarations/model/-private/hooks.d.ts +0 -10
  228. package/dist/unpkg/dev-deprecated/declarations/model/-private/legacy-relationships-support.d.ts +0 -47
  229. package/dist/unpkg/dev-deprecated/declarations/model/-private/model-for-mixin.d.ts +0 -3
  230. package/dist/unpkg/dev-deprecated/declarations/model/-private/model-methods.d.ts +0 -39
  231. package/dist/unpkg/dev-deprecated/declarations/model/-private/model.d.ts +0 -1269
  232. package/dist/unpkg/dev-deprecated/declarations/model/-private/notify-changes.d.ts +0 -4
  233. package/dist/unpkg/dev-deprecated/declarations/model/-private/promise-belongs-to.d.ts +0 -40
  234. package/dist/unpkg/dev-deprecated/declarations/model/-private/promise-many-array.d.ts +0 -124
  235. package/dist/unpkg/dev-deprecated/declarations/model/-private/record-state.d.ts +0 -58
  236. package/dist/unpkg/dev-deprecated/declarations/model/-private/references/belongs-to.d.ts +0 -498
  237. package/dist/unpkg/dev-deprecated/declarations/model/-private/references/has-many.d.ts +0 -500
  238. package/dist/unpkg/dev-deprecated/declarations/model/-private/schema-provider.d.ts +0 -56
  239. package/dist/unpkg/dev-deprecated/declarations/model/-private/type-utils.d.ts +0 -57
  240. package/dist/unpkg/dev-deprecated/declarations/model/-private/util.d.ts +0 -5
  241. package/dist/unpkg/dev-deprecated/declarations/model/-private.d.ts +0 -8
  242. package/dist/unpkg/dev-deprecated/declarations/model/migration-support.d.ts +0 -280
  243. package/dist/unpkg/dev-deprecated/declarations/model-fragments/extensions/fragment-array.d.ts +0 -16
  244. package/dist/unpkg/dev-deprecated/declarations/model-fragments/extensions/fragment.d.ts +0 -15
  245. package/dist/unpkg/dev-deprecated/declarations/model-fragments/hooks/model-for.d.ts +0 -20
  246. package/dist/unpkg/dev-deprecated/declarations/model-fragments/index.d.ts +0 -5
  247. package/dist/unpkg/dev-deprecated/declarations/model-fragments/instance-initializers/fragment-extensions.d.ts +0 -9
  248. package/dist/unpkg/dev-deprecated/declarations/model-fragments/utilities/with-array-defaults.d.ts +0 -15
  249. package/dist/unpkg/dev-deprecated/declarations/model-fragments/utilities/with-fragment-array-defaults.d.ts +0 -20
  250. package/dist/unpkg/dev-deprecated/declarations/model-fragments/utilities/with-fragment-defaults.d.ts +0 -19
  251. package/dist/unpkg/dev-deprecated/declarations/model-fragments/utilities/with-legacy.d.ts +0 -3
  252. package/dist/unpkg/dev-deprecated/declarations/model-fragments.d.ts +0 -9
  253. package/dist/unpkg/dev-deprecated/declarations/model.d.ts +0 -49
  254. package/dist/unpkg/dev-deprecated/declarations/serializer/-private/embedded-records-mixin.d.ts +0 -91
  255. package/dist/unpkg/dev-deprecated/declarations/serializer/-private/transforms/boolean.d.ts +0 -47
  256. package/dist/unpkg/dev-deprecated/declarations/serializer/-private/transforms/date.d.ts +0 -28
  257. package/dist/unpkg/dev-deprecated/declarations/serializer/-private/transforms/number.d.ts +0 -29
  258. package/dist/unpkg/dev-deprecated/declarations/serializer/-private/transforms/string.d.ts +0 -29
  259. package/dist/unpkg/dev-deprecated/declarations/serializer/-private/transforms/transform.d.ts +0 -118
  260. package/dist/unpkg/dev-deprecated/declarations/serializer/-private/utils.d.ts +0 -3
  261. package/dist/unpkg/dev-deprecated/declarations/serializer/json-api.d.ts +0 -123
  262. package/dist/unpkg/dev-deprecated/declarations/serializer/json.d.ts +0 -75
  263. package/dist/unpkg/dev-deprecated/declarations/serializer/rest.d.ts +0 -51
  264. package/dist/unpkg/dev-deprecated/declarations/serializer/transform.d.ts +0 -5
  265. package/dist/unpkg/dev-deprecated/declarations/serializer.d.ts +0 -254
  266. package/dist/unpkg/dev-deprecated/declarations/store/-private.d.ts +0 -223
  267. package/dist/unpkg/dev-deprecated/declarations/store.d.ts +0 -3
  268. package/dist/unpkg/dev-deprecated/util-Dul6TZts.js +0 -35
  269. package/dist/unpkg/dev-deprecated/utils-Cqw9eRj5.js +0 -23
  270. package/dist/unpkg/prod/declarations/adapter/-private/build-url-mixin.d.ts +0 -33
  271. package/dist/unpkg/prod/declarations/adapter/-private/fastboot-interface.d.ts +0 -8
  272. package/dist/unpkg/prod/declarations/adapter/-private/utils/continue-on-reject.d.ts +0 -1
  273. package/dist/unpkg/prod/declarations/adapter/-private/utils/determine-body-promise.d.ts +0 -4
  274. package/dist/unpkg/prod/declarations/adapter/-private/utils/fetch.d.ts +0 -8
  275. package/dist/unpkg/prod/declarations/adapter/-private/utils/parse-response-headers.d.ts +0 -1
  276. package/dist/unpkg/prod/declarations/adapter/-private/utils/serialize-into-hash.d.ts +0 -6
  277. package/dist/unpkg/prod/declarations/adapter/-private/utils/serialize-query-params.d.ts +0 -5
  278. package/dist/unpkg/prod/declarations/adapter/-private.d.ts +0 -5
  279. package/dist/unpkg/prod/declarations/adapter/error.d.ts +0 -215
  280. package/dist/unpkg/prod/declarations/adapter/json-api.d.ts +0 -231
  281. package/dist/unpkg/prod/declarations/adapter/rest.d.ts +0 -815
  282. package/dist/unpkg/prod/declarations/adapter.d.ts +0 -770
  283. package/dist/unpkg/prod/declarations/compat/-private.d.ts +0 -13
  284. package/dist/unpkg/prod/declarations/compat/builders/find-all.d.ts +0 -35
  285. package/dist/unpkg/prod/declarations/compat/builders/find-record.d.ts +0 -56
  286. package/dist/unpkg/prod/declarations/compat/builders/query.d.ts +0 -66
  287. package/dist/unpkg/prod/declarations/compat/builders/save-record.d.ts +0 -34
  288. package/dist/unpkg/prod/declarations/compat/builders/utils.d.ts +0 -3
  289. package/dist/unpkg/prod/declarations/compat/builders.d.ts +0 -14
  290. package/dist/unpkg/prod/declarations/compat/extensions.d.ts +0 -59
  291. package/dist/unpkg/prod/declarations/compat/legacy-network-handler/fetch-manager.d.ts +0 -55
  292. package/dist/unpkg/prod/declarations/compat/legacy-network-handler/identifier-has-id.d.ts +0 -2
  293. package/dist/unpkg/prod/declarations/compat/legacy-network-handler/legacy-data-fetch.d.ts +0 -11
  294. package/dist/unpkg/prod/declarations/compat/legacy-network-handler/legacy-data-utils.d.ts +0 -5
  295. package/dist/unpkg/prod/declarations/compat/legacy-network-handler/legacy-network-handler.d.ts +0 -2
  296. package/dist/unpkg/prod/declarations/compat/legacy-network-handler/minimum-adapter-interface.d.ts +0 -524
  297. package/dist/unpkg/prod/declarations/compat/legacy-network-handler/minimum-serializer-interface.d.ts +0 -213
  298. package/dist/unpkg/prod/declarations/compat/legacy-network-handler/serializer-response.d.ts +0 -6
  299. package/dist/unpkg/prod/declarations/compat/legacy-network-handler/snapshot-record-array.d.ts +0 -110
  300. package/dist/unpkg/prod/declarations/compat/legacy-network-handler/snapshot.d.ts +0 -255
  301. package/dist/unpkg/prod/declarations/compat/utils.d.ts +0 -137
  302. package/dist/unpkg/prod/declarations/compat.d.ts +0 -157
  303. package/dist/unpkg/prod/declarations/index.d.ts +0 -70
  304. package/dist/unpkg/prod/declarations/model/-private/attr.d.ts +0 -170
  305. package/dist/unpkg/prod/declarations/model/-private/belongs-to.d.ts +0 -174
  306. package/dist/unpkg/prod/declarations/model/-private/debug/assert-polymorphic-type.d.ts +0 -5
  307. package/dist/unpkg/prod/declarations/model/-private/errors.d.ts +0 -289
  308. package/dist/unpkg/prod/declarations/model/-private/has-many.d.ts +0 -162
  309. package/dist/unpkg/prod/declarations/model/-private/hooks.d.ts +0 -10
  310. package/dist/unpkg/prod/declarations/model/-private/legacy-relationships-support.d.ts +0 -47
  311. package/dist/unpkg/prod/declarations/model/-private/model-for-mixin.d.ts +0 -3
  312. package/dist/unpkg/prod/declarations/model/-private/model-methods.d.ts +0 -39
  313. package/dist/unpkg/prod/declarations/model/-private/model.d.ts +0 -1269
  314. package/dist/unpkg/prod/declarations/model/-private/notify-changes.d.ts +0 -4
  315. package/dist/unpkg/prod/declarations/model/-private/promise-belongs-to.d.ts +0 -40
  316. package/dist/unpkg/prod/declarations/model/-private/promise-many-array.d.ts +0 -124
  317. package/dist/unpkg/prod/declarations/model/-private/record-state.d.ts +0 -58
  318. package/dist/unpkg/prod/declarations/model/-private/references/belongs-to.d.ts +0 -498
  319. package/dist/unpkg/prod/declarations/model/-private/references/has-many.d.ts +0 -500
  320. package/dist/unpkg/prod/declarations/model/-private/schema-provider.d.ts +0 -56
  321. package/dist/unpkg/prod/declarations/model/-private/type-utils.d.ts +0 -57
  322. package/dist/unpkg/prod/declarations/model/-private/util.d.ts +0 -5
  323. package/dist/unpkg/prod/declarations/model/-private.d.ts +0 -8
  324. package/dist/unpkg/prod/declarations/model/migration-support.d.ts +0 -280
  325. package/dist/unpkg/prod/declarations/model-fragments/extensions/fragment-array.d.ts +0 -16
  326. package/dist/unpkg/prod/declarations/model-fragments/extensions/fragment.d.ts +0 -15
  327. package/dist/unpkg/prod/declarations/model-fragments/hooks/model-for.d.ts +0 -20
  328. package/dist/unpkg/prod/declarations/model-fragments/index.d.ts +0 -5
  329. package/dist/unpkg/prod/declarations/model-fragments/instance-initializers/fragment-extensions.d.ts +0 -9
  330. package/dist/unpkg/prod/declarations/model-fragments/utilities/with-array-defaults.d.ts +0 -15
  331. package/dist/unpkg/prod/declarations/model-fragments/utilities/with-fragment-array-defaults.d.ts +0 -20
  332. package/dist/unpkg/prod/declarations/model-fragments/utilities/with-fragment-defaults.d.ts +0 -19
  333. package/dist/unpkg/prod/declarations/model-fragments/utilities/with-legacy.d.ts +0 -3
  334. package/dist/unpkg/prod/declarations/model-fragments.d.ts +0 -9
  335. package/dist/unpkg/prod/declarations/model.d.ts +0 -49
  336. package/dist/unpkg/prod/declarations/serializer/-private/embedded-records-mixin.d.ts +0 -91
  337. package/dist/unpkg/prod/declarations/serializer/-private/transforms/boolean.d.ts +0 -47
  338. package/dist/unpkg/prod/declarations/serializer/-private/transforms/date.d.ts +0 -28
  339. package/dist/unpkg/prod/declarations/serializer/-private/transforms/number.d.ts +0 -29
  340. package/dist/unpkg/prod/declarations/serializer/-private/transforms/string.d.ts +0 -29
  341. package/dist/unpkg/prod/declarations/serializer/-private/transforms/transform.d.ts +0 -118
  342. package/dist/unpkg/prod/declarations/serializer/-private/utils.d.ts +0 -3
  343. package/dist/unpkg/prod/declarations/serializer/json-api.d.ts +0 -123
  344. package/dist/unpkg/prod/declarations/serializer/json.d.ts +0 -75
  345. package/dist/unpkg/prod/declarations/serializer/rest.d.ts +0 -51
  346. package/dist/unpkg/prod/declarations/serializer/transform.d.ts +0 -5
  347. package/dist/unpkg/prod/declarations/serializer.d.ts +0 -254
  348. package/dist/unpkg/prod/declarations/store/-private.d.ts +0 -223
  349. package/dist/unpkg/prod/declarations/store.d.ts +0 -3
  350. package/dist/unpkg/prod/hooks-QqRnX108.js +0 -74
  351. package/dist/unpkg/prod/util-Dul6TZts.js +0 -35
  352. package/dist/unpkg/prod/utils-Cqw9eRj5.js +0 -23
  353. package/dist/unpkg/prod-deprecated/declarations/adapter/-private/build-url-mixin.d.ts +0 -33
  354. package/dist/unpkg/prod-deprecated/declarations/adapter/-private/fastboot-interface.d.ts +0 -8
  355. package/dist/unpkg/prod-deprecated/declarations/adapter/-private/utils/continue-on-reject.d.ts +0 -1
  356. package/dist/unpkg/prod-deprecated/declarations/adapter/-private/utils/determine-body-promise.d.ts +0 -4
  357. package/dist/unpkg/prod-deprecated/declarations/adapter/-private/utils/fetch.d.ts +0 -8
  358. package/dist/unpkg/prod-deprecated/declarations/adapter/-private/utils/parse-response-headers.d.ts +0 -1
  359. package/dist/unpkg/prod-deprecated/declarations/adapter/-private/utils/serialize-into-hash.d.ts +0 -6
  360. package/dist/unpkg/prod-deprecated/declarations/adapter/-private/utils/serialize-query-params.d.ts +0 -5
  361. package/dist/unpkg/prod-deprecated/declarations/adapter/-private.d.ts +0 -5
  362. package/dist/unpkg/prod-deprecated/declarations/adapter/error.d.ts +0 -215
  363. package/dist/unpkg/prod-deprecated/declarations/adapter/json-api.d.ts +0 -231
  364. package/dist/unpkg/prod-deprecated/declarations/adapter/rest.d.ts +0 -815
  365. package/dist/unpkg/prod-deprecated/declarations/adapter.d.ts +0 -770
  366. package/dist/unpkg/prod-deprecated/declarations/compat/-private.d.ts +0 -13
  367. package/dist/unpkg/prod-deprecated/declarations/compat/builders/find-all.d.ts +0 -35
  368. package/dist/unpkg/prod-deprecated/declarations/compat/builders/find-record.d.ts +0 -56
  369. package/dist/unpkg/prod-deprecated/declarations/compat/builders/query.d.ts +0 -66
  370. package/dist/unpkg/prod-deprecated/declarations/compat/builders/save-record.d.ts +0 -34
  371. package/dist/unpkg/prod-deprecated/declarations/compat/builders/utils.d.ts +0 -3
  372. package/dist/unpkg/prod-deprecated/declarations/compat/builders.d.ts +0 -14
  373. package/dist/unpkg/prod-deprecated/declarations/compat/extensions.d.ts +0 -59
  374. package/dist/unpkg/prod-deprecated/declarations/compat/legacy-network-handler/fetch-manager.d.ts +0 -55
  375. package/dist/unpkg/prod-deprecated/declarations/compat/legacy-network-handler/identifier-has-id.d.ts +0 -2
  376. package/dist/unpkg/prod-deprecated/declarations/compat/legacy-network-handler/legacy-data-fetch.d.ts +0 -11
  377. package/dist/unpkg/prod-deprecated/declarations/compat/legacy-network-handler/legacy-data-utils.d.ts +0 -5
  378. package/dist/unpkg/prod-deprecated/declarations/compat/legacy-network-handler/legacy-network-handler.d.ts +0 -2
  379. package/dist/unpkg/prod-deprecated/declarations/compat/legacy-network-handler/minimum-adapter-interface.d.ts +0 -524
  380. package/dist/unpkg/prod-deprecated/declarations/compat/legacy-network-handler/minimum-serializer-interface.d.ts +0 -213
  381. package/dist/unpkg/prod-deprecated/declarations/compat/legacy-network-handler/serializer-response.d.ts +0 -6
  382. package/dist/unpkg/prod-deprecated/declarations/compat/legacy-network-handler/snapshot-record-array.d.ts +0 -110
  383. package/dist/unpkg/prod-deprecated/declarations/compat/legacy-network-handler/snapshot.d.ts +0 -255
  384. package/dist/unpkg/prod-deprecated/declarations/compat/utils.d.ts +0 -137
  385. package/dist/unpkg/prod-deprecated/declarations/compat.d.ts +0 -157
  386. package/dist/unpkg/prod-deprecated/declarations/index.d.ts +0 -70
  387. package/dist/unpkg/prod-deprecated/declarations/model/-private/attr.d.ts +0 -170
  388. package/dist/unpkg/prod-deprecated/declarations/model/-private/belongs-to.d.ts +0 -174
  389. package/dist/unpkg/prod-deprecated/declarations/model/-private/debug/assert-polymorphic-type.d.ts +0 -5
  390. package/dist/unpkg/prod-deprecated/declarations/model/-private/errors.d.ts +0 -289
  391. package/dist/unpkg/prod-deprecated/declarations/model/-private/has-many.d.ts +0 -162
  392. package/dist/unpkg/prod-deprecated/declarations/model/-private/hooks.d.ts +0 -10
  393. package/dist/unpkg/prod-deprecated/declarations/model/-private/legacy-relationships-support.d.ts +0 -47
  394. package/dist/unpkg/prod-deprecated/declarations/model/-private/model-for-mixin.d.ts +0 -3
  395. package/dist/unpkg/prod-deprecated/declarations/model/-private/model-methods.d.ts +0 -39
  396. package/dist/unpkg/prod-deprecated/declarations/model/-private/model.d.ts +0 -1269
  397. package/dist/unpkg/prod-deprecated/declarations/model/-private/notify-changes.d.ts +0 -4
  398. package/dist/unpkg/prod-deprecated/declarations/model/-private/promise-belongs-to.d.ts +0 -40
  399. package/dist/unpkg/prod-deprecated/declarations/model/-private/promise-many-array.d.ts +0 -124
  400. package/dist/unpkg/prod-deprecated/declarations/model/-private/record-state.d.ts +0 -58
  401. package/dist/unpkg/prod-deprecated/declarations/model/-private/references/belongs-to.d.ts +0 -498
  402. package/dist/unpkg/prod-deprecated/declarations/model/-private/references/has-many.d.ts +0 -500
  403. package/dist/unpkg/prod-deprecated/declarations/model/-private/schema-provider.d.ts +0 -56
  404. package/dist/unpkg/prod-deprecated/declarations/model/-private/type-utils.d.ts +0 -57
  405. package/dist/unpkg/prod-deprecated/declarations/model/-private/util.d.ts +0 -5
  406. package/dist/unpkg/prod-deprecated/declarations/model/-private.d.ts +0 -8
  407. package/dist/unpkg/prod-deprecated/declarations/model/migration-support.d.ts +0 -280
  408. package/dist/unpkg/prod-deprecated/declarations/model-fragments/extensions/fragment-array.d.ts +0 -16
  409. package/dist/unpkg/prod-deprecated/declarations/model-fragments/extensions/fragment.d.ts +0 -15
  410. package/dist/unpkg/prod-deprecated/declarations/model-fragments/hooks/model-for.d.ts +0 -20
  411. package/dist/unpkg/prod-deprecated/declarations/model-fragments/index.d.ts +0 -5
  412. package/dist/unpkg/prod-deprecated/declarations/model-fragments/instance-initializers/fragment-extensions.d.ts +0 -9
  413. package/dist/unpkg/prod-deprecated/declarations/model-fragments/utilities/with-array-defaults.d.ts +0 -15
  414. package/dist/unpkg/prod-deprecated/declarations/model-fragments/utilities/with-fragment-array-defaults.d.ts +0 -20
  415. package/dist/unpkg/prod-deprecated/declarations/model-fragments/utilities/with-fragment-defaults.d.ts +0 -19
  416. package/dist/unpkg/prod-deprecated/declarations/model-fragments/utilities/with-legacy.d.ts +0 -3
  417. package/dist/unpkg/prod-deprecated/declarations/model-fragments.d.ts +0 -9
  418. package/dist/unpkg/prod-deprecated/declarations/model.d.ts +0 -49
  419. package/dist/unpkg/prod-deprecated/declarations/serializer/-private/embedded-records-mixin.d.ts +0 -91
  420. package/dist/unpkg/prod-deprecated/declarations/serializer/-private/transforms/boolean.d.ts +0 -47
  421. package/dist/unpkg/prod-deprecated/declarations/serializer/-private/transforms/date.d.ts +0 -28
  422. package/dist/unpkg/prod-deprecated/declarations/serializer/-private/transforms/number.d.ts +0 -29
  423. package/dist/unpkg/prod-deprecated/declarations/serializer/-private/transforms/string.d.ts +0 -29
  424. package/dist/unpkg/prod-deprecated/declarations/serializer/-private/transforms/transform.d.ts +0 -118
  425. package/dist/unpkg/prod-deprecated/declarations/serializer/-private/utils.d.ts +0 -3
  426. package/dist/unpkg/prod-deprecated/declarations/serializer/json-api.d.ts +0 -123
  427. package/dist/unpkg/prod-deprecated/declarations/serializer/json.d.ts +0 -75
  428. package/dist/unpkg/prod-deprecated/declarations/serializer/rest.d.ts +0 -51
  429. package/dist/unpkg/prod-deprecated/declarations/serializer/transform.d.ts +0 -5
  430. package/dist/unpkg/prod-deprecated/declarations/serializer.d.ts +0 -254
  431. package/dist/unpkg/prod-deprecated/declarations/store/-private.d.ts +0 -223
  432. package/dist/unpkg/prod-deprecated/declarations/store.d.ts +0 -3
  433. package/dist/unpkg/prod-deprecated/utils-Cqw9eRj5.js +0 -23
@@ -1,16 +1,14 @@
1
1
  import { getOwner } from '@ember/application';
2
- import { deprecate } from '@ember/debug';
3
2
  import EmberObject from '@ember/object';
4
3
  import { recordIdentifierFor, storeFor } from '@warp-drive/core';
5
4
  import { assertPrivateStore, notifyInternalSignal, peekInternalSignal, withSignalStore, recordIdentifierFor as recordIdentifierFor$1, gate, memoized, defineSignal, coerceId, entangleSignal, defineGate } from '@warp-drive/core/store/-private';
6
5
  import { RecordStore } from '@warp-drive/core/types/symbols';
7
- import { l as lookupLegacySupport, L as LEGACY_SUPPORT, E as Errors } from "./errors-CIGPcDvd.js";
8
- import { u as upgradeStore, F as FetchManager } from "./-private-B1pSSN52.js";
9
- import { macroCondition, getGlobalConfig } from '@embroider/macros';
6
+ import { l as lookupLegacySupport, L as LEGACY_SUPPORT, E as Errors } from "./errors-CG1SPYVg.js";
7
+ import { u as upgradeStore, F as FetchManager } from "./-private-Cvf_97EG.js";
10
8
  import { cacheFor } from '@ember/object/internals';
11
9
  import { Context } from '@warp-drive/core/reactive/-private';
12
10
  import { d as decorateMethodV2 } from "./runtime-BPCpkOf1-BKOwiRJp.js";
13
- import { n as normalizeModelName } from "./util-Dul6TZts.js";
11
+ import { n as normalizeModelName } from "./util-B6cn-i93.js";
14
12
  function rollbackAttributes() {
15
13
  const {
16
14
  currentState
@@ -42,23 +40,7 @@ function hasMany(prop) {
42
40
  return lookupLegacySupport(this).referenceFor('hasMany', prop);
43
41
  }
44
42
  function reload(options = {}) {
45
- if (macroCondition(!getGlobalConfig().WarpDrive.deprecations.ENABLE_LEGACY_REQUEST_METHODS)) {
46
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
47
- {
48
- throw new Error(`You cannot use reload() on a record when ENABLE_LEGACY_REQUEST_METHODS is false.`);
49
- }
50
- })() : {};
51
- } else {
52
- deprecate(`record.reload is deprecated, please use store.request to initiate a request instead.`, false, {
53
- id: 'warp-drive:deprecate-legacy-request-methods',
54
- until: '6.0',
55
- for: '@warp-drive/core',
56
- url: 'https://docs.warp-drive.io/api/@warp-drive/core/build-config/deprecations/variables/ENABLE_LEGACY_REQUEST_METHODS',
57
- since: {
58
- enabled: '5.7',
59
- available: '5.7'
60
- }
61
- });
43
+ {
62
44
  return _reload.call(this, options);
63
45
  }
64
46
  }
@@ -66,11 +48,6 @@ function _reload(options = {}) {
66
48
  options.isReloading = true;
67
49
  options.reload = true;
68
50
  const identifier = recordIdentifierFor(this);
69
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
70
- if (!test) {
71
- throw new Error(`You cannot reload a record without an ID`);
72
- }
73
- })(identifier.id) : {};
74
51
  this.isReloading = true;
75
52
  const promise = this[RecordStore].request({
76
53
  op: 'findRecord',
@@ -100,23 +77,7 @@ function deleteRecord() {
100
77
  }
101
78
  }
102
79
  function save(options) {
103
- if (macroCondition(!getGlobalConfig().WarpDrive.deprecations.ENABLE_LEGACY_REQUEST_METHODS)) {
104
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
105
- {
106
- throw new Error(`You cannot use save() on a record when ENABLE_LEGACY_REQUEST_METHODS is false.`);
107
- }
108
- })() : {};
109
- } else {
110
- deprecate(`record.save is deprecated, please use store.request to initiate a request instead.`, false, {
111
- id: 'warp-drive:deprecate-legacy-request-methods',
112
- until: '6.0',
113
- for: '@warp-drive/core',
114
- url: 'https://docs.warp-drive.io/api/@warp-drive/core/build-config/deprecations/variables/ENABLE_LEGACY_REQUEST_METHODS',
115
- since: {
116
- enabled: '5.7',
117
- available: '5.7'
118
- }
119
- });
80
+ {
120
81
  return _save.call(this, options);
121
82
  }
122
83
  }
@@ -131,23 +92,7 @@ function _save(options) {
131
92
  return promise;
132
93
  }
133
94
  function destroyRecord(options) {
134
- if (macroCondition(!getGlobalConfig().WarpDrive.deprecations.ENABLE_LEGACY_REQUEST_METHODS)) {
135
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
136
- {
137
- throw new Error(`You cannot use destroyRecord() on a record when ENABLE_LEGACY_REQUEST_METHODS is false.`);
138
- }
139
- })() : {};
140
- } else {
141
- deprecate(`record.destroyRecord is deprecated, please use store.request to initiate a request instead.`, false, {
142
- id: 'warp-drive:deprecate-legacy-request-methods',
143
- until: '6.0',
144
- for: '@warp-drive/core',
145
- url: 'https://docs.warp-drive.io/api/@warp-drive/core/build-config/deprecations/variables/ENABLE_LEGACY_REQUEST_METHODS',
146
- since: {
147
- enabled: '5.7',
148
- available: '5.7'
149
- }
150
- });
95
+ {
151
96
  return _destroyRecord.call(this, options);
152
97
  }
153
98
  }
@@ -188,11 +133,6 @@ function notifyChanges(identifier, value, key, record, store) {
188
133
  case 'relationships':
189
134
  if (key) {
190
135
  const meta = record.constructor.relationshipsByName.get(key);
191
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
192
- if (!test) {
193
- throw new Error(`Expected to find a relationship for ${key} on ${identifier.type}`);
194
- }
195
- })(meta) : {};
196
136
  notifyRelationship(identifier, key, record, meta);
197
137
  } else {
198
138
  record.eachRelationship((name, meta) => {
@@ -219,20 +159,6 @@ function notifyRelationship(identifier, key, record, meta) {
219
159
  }
220
160
  if (manyArray) {
221
161
  notifyInternalSignal(manyArray[Context].signal);
222
-
223
- //We need to notifyPropertyChange in the adding case because we need to make sure
224
- //we fetch the newly added record in case it is unloaded
225
- //TODO(Igor): Consider whether we could do this only if the record state is unloaded
226
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
227
- if (!test) {
228
- throw new Error(`Expected options to exist on relationship meta`);
229
- }
230
- })(meta.options) : {};
231
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
232
- if (!test) {
233
- throw new Error(`Expected async to exist on relationship meta options`);
234
- }
235
- })('async' in meta.options) : {};
236
162
  if (meta.options.async) {
237
163
  record.notifyPropertyChange(key);
238
164
  }
@@ -422,11 +348,6 @@ class RecordState {
422
348
 
423
349
  /** @internal */
424
350
  updateInvalidErrors(errors) {
425
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
426
- if (!test) {
427
- throw new Error(`Expected the Cache instance for ${this.identifier.lid} to implement getErrors(identifier)`);
428
- }
429
- })(typeof this.cache.getErrors === 'function') : {};
430
351
  const jsonApiErrors = this.cache.getErrors(this.identifier);
431
352
  errors.clear();
432
353
  for (let i = 0; i < jsonApiErrors.length; i++) {
@@ -441,11 +362,6 @@ class RecordState {
441
362
  }
442
363
  if (key) {
443
364
  const errMsg = error.detail || error.title;
444
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
445
- if (!test) {
446
- throw new Error(`Expected field error to have a detail or title to use as the message`);
447
- }
448
- })(errMsg) : {};
449
365
  errors.add(key, errMsg);
450
366
  }
451
367
  }
@@ -478,11 +394,6 @@ class RecordState {
478
394
  get isSaved() {
479
395
  const rd = this.cache;
480
396
  if (this.isDeleted) {
481
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
482
- if (!test) {
483
- throw new Error(`Expected Cache to implement isDeletionCommitted()`);
484
- }
485
- })(typeof rd.isDeletionCommitted === 'function') : {};
486
397
  return rd.isDeletionCommitted(this.identifier);
487
398
  }
488
399
  if (this.isNew || this.isEmpty || !this.isValid || this.isDirty || this.isLoading) {
@@ -495,13 +406,6 @@ class RecordState {
495
406
  }
496
407
  get isEmpty() {
497
408
  const rd = this.cache;
498
- // TODO this is not actually an RFC'd concept. Determine the
499
- // correct heuristic to replace this with.
500
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
501
- if (!test) {
502
- throw new Error(`Expected Cache to implement isEmpty()`);
503
- }
504
- })(typeof rd.isEmpty === 'function') : {};
505
409
  return !this.isNew && rd.isEmpty(this.identifier);
506
410
  }
507
411
  static {
@@ -509,11 +413,6 @@ class RecordState {
509
413
  }
510
414
  get isNew() {
511
415
  const rd = this.cache;
512
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
513
- if (!test) {
514
- throw new Error(`Expected Cache to implement isNew()`);
515
- }
516
- })(typeof rd.isNew === 'function') : {};
517
416
  return rd.isNew(this.identifier);
518
417
  }
519
418
  static {
@@ -521,11 +420,6 @@ class RecordState {
521
420
  }
522
421
  get isDeleted() {
523
422
  const rd = this.cache;
524
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
525
- if (!test) {
526
- throw new Error(`Expected Cache to implement isDeleted()`);
527
- }
528
- })(typeof rd.isDeleted === 'function') : {};
529
423
  return rd.isDeleted(this.identifier);
530
424
  }
531
425
  static {
@@ -730,11 +624,6 @@ function computeOnce(target, propertyName, desc) {
730
624
  class Model extends EmberObject {
731
625
  /** @internal */
732
626
  init(options) {
733
- if (macroCondition(getGlobalConfig().WarpDrive.env.DEBUG)) {
734
- if (!options?._secretInit && !options?._createProps) {
735
- throw new Error('You should not call `create` on a model. Instead, call `store.createRecord` with the attributes you would like to set.');
736
- }
737
- }
738
627
  const createProps = options._createProps;
739
628
  const _secretInit = options._secretInit;
740
629
  options._createProps = null;
@@ -744,7 +633,7 @@ class Model extends EmberObject {
744
633
  this[RecordStore] = store;
745
634
  const identity = _secretInit.identifier;
746
635
  _secretInit.cb(this, identity, _secretInit.store);
747
- this.___recordState = macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? new RecordState(this) : null;
636
+ this.___recordState = null;
748
637
  this.setProperties(createProps);
749
638
  const notifications = store.notifications;
750
639
  this.___private_notifications = notifications.subscribe(identity, (identifier, type, field) => {
@@ -999,11 +888,7 @@ class Model extends EmberObject {
999
888
  static {
1000
889
  decorateMethodV2(this.prototype, "isError", [memoized]);
1001
890
  }
1002
- set isError(v) {
1003
- if (macroCondition(getGlobalConfig().WarpDrive.env.DEBUG)) {
1004
- throw new Error(`isError is not directly settable`);
1005
- }
1006
- }
891
+ set isError(v) {}
1007
892
 
1008
893
  /**
1009
894
  If `true` the store is attempting to reload the record from the adapter.
@@ -1037,13 +922,7 @@ class Model extends EmberObject {
1037
922
  // this guard exists, because some dev-only deprecation code
1038
923
  // (addListener via validatePropertyInjections) invokes toString before the
1039
924
  // object is real.
1040
- if (macroCondition(getGlobalConfig().WarpDrive.env.DEBUG)) {
1041
- try {
1042
- return recordIdentifierFor(this).id;
1043
- } catch {
1044
- return null;
1045
- }
1046
- }
925
+
1047
926
  return recordIdentifierFor(this).id;
1048
927
  }
1049
928
  static {
@@ -1054,11 +933,6 @@ class Model extends EmberObject {
1054
933
  const identifier = recordIdentifierFor(this);
1055
934
  const didChange = normalizedId !== identifier.id;
1056
935
  assertPrivateStore(this.store);
1057
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1058
- if (!test) {
1059
- throw new Error(`Cannot set ${identifier.type} record's id to ${id}, because id is already ${identifier.id}`);
1060
- }
1061
- })(!didChange || identifier.id === null) : {};
1062
936
  if (normalizedId !== null && didChange) {
1063
937
  this.store._instanceCache.setRecordId(identifier, normalizedId);
1064
938
  this.store.notifications.notify(identifier, 'identity', null);
@@ -1079,7 +953,7 @@ class Model extends EmberObject {
1079
953
  // when using legacy/classic ember classes. Basically: lazy in prod and eager in dev.
1080
954
  // so we do this to try to steer folks to the nicer "dont user currentState"
1081
955
  // error.
1082
- if (macroCondition(!getGlobalConfig().WarpDrive.env.DEBUG)) {
956
+ {
1083
957
  if (!this.___recordState) {
1084
958
  this.___recordState = new RecordState(this);
1085
959
  }
@@ -1185,13 +1059,7 @@ class Model extends EmberObject {
1185
1059
  }
1186
1060
 
1187
1061
  /** @internal */
1188
- attr() {
1189
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1190
- {
1191
- throw new Error('The `attr` method is not available on Model, a Snapshot was probably expected. Are you passing a Model instead of a Snapshot to your serializer?');
1192
- }
1193
- })() : {};
1194
- }
1062
+ attr() {}
1195
1063
 
1196
1064
  /**
1197
1065
  Given a callback, iterates over each of the relationships in the model,
@@ -1306,20 +1174,10 @@ class Model extends EmberObject {
1306
1174
  @return the type of the relationship, or undefined
1307
1175
  */
1308
1176
  static typeForRelationship(name, store) {
1309
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1310
- if (!test) {
1311
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1312
- }
1313
- })(this.modelName) : {};
1314
1177
  const relationship = this.relationshipsByName.get(name);
1315
1178
  return relationship && store.modelFor(relationship.type);
1316
1179
  }
1317
1180
  static get inverseMap() {
1318
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1319
- if (!test) {
1320
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1321
- }
1322
- })(this.modelName) : {};
1323
1181
  return Object.create(null);
1324
1182
  }
1325
1183
 
@@ -1351,11 +1209,6 @@ class Model extends EmberObject {
1351
1209
  decorateMethodV2(this, "inverseMap", [computeOnce]);
1352
1210
  }
1353
1211
  static inverseFor(name, store) {
1354
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1355
- if (!test) {
1356
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1357
- }
1358
- })(this.modelName) : {};
1359
1212
  const inverseMap = this.inverseMap;
1360
1213
  if (inverseMap[name]) {
1361
1214
  return inverseMap[name];
@@ -1368,46 +1221,21 @@ class Model extends EmberObject {
1368
1221
 
1369
1222
  //Calculate the inverse, ignoring the cache
1370
1223
  static _findInverseFor(name, store) {
1371
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1372
- if (!test) {
1373
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1374
- }
1375
- })(this.modelName) : {};
1376
1224
  const relationship = this.relationshipsByName.get(name);
1377
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1378
- if (!test) {
1379
- throw new Error(`No relationship named '${name}' on '${this.modelName}' exists.`);
1380
- }
1381
- })(relationship) : {};
1382
1225
  if (!relationship) {
1383
1226
  return null;
1384
1227
  }
1385
1228
  const {
1386
1229
  options
1387
1230
  } = relationship;
1388
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1389
- if (!test) {
1390
- throw new Error(`Expected the relationship ${name} on ${this.modelName} to define an inverse.`);
1391
- }
1392
- })(options.inverse === null || typeof options.inverse === 'string' && options.inverse.length > 0) : {};
1393
1231
  if (options.inverse === null) {
1394
1232
  return null;
1395
1233
  }
1396
1234
  const schemaExists = store.schema.hasResource(relationship);
1397
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1398
- if (!test) {
1399
- throw new Error(`No associated schema found for '${relationship.type}' while calculating the inverse of ${name} on ${this.modelName}`);
1400
- }
1401
- })(schemaExists) : {};
1402
1235
  if (!schemaExists) {
1403
1236
  return null;
1404
1237
  }
1405
1238
  const inverseField = store.schema.fields(relationship).get(options.inverse);
1406
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1407
- if (!test) {
1408
- throw new Error(`No inverse relationship found for '${name}' on '${this.modelName}'`);
1409
- }
1410
- })(inverseField && (inverseField.kind === 'belongsTo' || inverseField.kind === 'hasMany')) : {};
1411
1239
  return inverseField || null;
1412
1240
  }
1413
1241
 
@@ -1444,11 +1272,6 @@ class Model extends EmberObject {
1444
1272
  */
1445
1273
 
1446
1274
  static get relationships() {
1447
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1448
- if (!test) {
1449
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1450
- }
1451
- })(this.modelName) : {};
1452
1275
  const map = new Map();
1453
1276
  const relationshipsByName = this.relationshipsByName;
1454
1277
 
@@ -1494,11 +1317,6 @@ class Model extends EmberObject {
1494
1317
  decorateMethodV2(this, "relationships", [computeOnce]);
1495
1318
  }
1496
1319
  static get relationshipNames() {
1497
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1498
- if (!test) {
1499
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1500
- }
1501
- })(this.modelName) : {};
1502
1320
  const names = {
1503
1321
  hasMany: [],
1504
1322
  belongsTo: []
@@ -1538,11 +1356,6 @@ class Model extends EmberObject {
1538
1356
  decorateMethodV2(this, "relationshipNames", [computeOnce]);
1539
1357
  }
1540
1358
  static get relatedTypes() {
1541
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1542
- if (!test) {
1543
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1544
- }
1545
- })(this.modelName) : {};
1546
1359
  const types = [];
1547
1360
  const rels = this.relationshipsObject;
1548
1361
  const relationships = Object.keys(rels);
@@ -1590,11 +1403,6 @@ class Model extends EmberObject {
1590
1403
  decorateMethodV2(this, "relatedTypes", [computeOnce]);
1591
1404
  }
1592
1405
  static get relationshipsByName() {
1593
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1594
- if (!test) {
1595
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1596
- }
1597
- })(this.modelName) : {};
1598
1406
  const map = new Map();
1599
1407
  const rels = this.relationshipsObject;
1600
1408
  const relationships = Object.keys(rels);
@@ -1609,13 +1417,8 @@ class Model extends EmberObject {
1609
1417
  decorateMethodV2(this, "relationshipsByName", [computeOnce]);
1610
1418
  }
1611
1419
  static get relationshipsObject() {
1612
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1613
- if (!test) {
1614
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1615
- }
1616
- })(this.modelName) : {};
1617
1420
  const relationships = Object.create(null);
1618
- const modelName = this.modelName;
1421
+ this.modelName;
1619
1422
  this.eachComputedProperty((name, meta) => {
1620
1423
  if (!isRelationshipSchema(meta)) {
1621
1424
  return;
@@ -1624,16 +1427,6 @@ class Model extends EmberObject {
1624
1427
  meta.key = name;
1625
1428
  meta.name = name;
1626
1429
  relationships[name] = meta;
1627
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1628
- if (!test) {
1629
- throw new Error(`Expected options in meta`);
1630
- }
1631
- })(meta.options && typeof meta.options === 'object') : {};
1632
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1633
- if (!test) {
1634
- throw new Error(`You should not specify both options.as and options.inverse as null on ${modelName}.${meta.name}, as if there is no inverse field there is no abstract type to conform to. You may have intended for this relationship to be polymorphic, or you may have mistakenly set inverse to null.`);
1635
- }
1636
- })(!(meta.options.inverse === null && meta.options.as?.length)) : {};
1637
1430
  });
1638
1431
  return relationships;
1639
1432
  }
@@ -1672,11 +1465,6 @@ class Model extends EmberObject {
1672
1465
  decorateMethodV2(this, "relationshipsObject", [computeOnce]);
1673
1466
  }
1674
1467
  static get fields() {
1675
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1676
- if (!test) {
1677
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1678
- }
1679
- })(this.modelName) : {};
1680
1468
  const map = new Map();
1681
1469
  this.eachComputedProperty((name, meta) => {
1682
1470
  if (isRelationshipSchema(meta)) {
@@ -1700,11 +1488,6 @@ class Model extends EmberObject {
1700
1488
  decorateMethodV2(this, "fields", [computeOnce]);
1701
1489
  }
1702
1490
  static eachRelationship(callback, binding) {
1703
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1704
- if (!test) {
1705
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1706
- }
1707
- })(this.modelName) : {};
1708
1491
  this.relationshipsByName.forEach((relationship, name) => {
1709
1492
  callback.call(binding, name, relationship);
1710
1493
  });
@@ -1720,11 +1503,6 @@ class Model extends EmberObject {
1720
1503
  @param {any} binding the value to which the callback's `this` should be bound
1721
1504
  */
1722
1505
  static eachRelatedType(callback, binding) {
1723
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1724
- if (!test) {
1725
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1726
- }
1727
- })(this.modelName) : {};
1728
1506
  const relationshipTypes = this.relatedTypes;
1729
1507
  for (let i = 0; i < relationshipTypes.length; i++) {
1730
1508
  const type = relationshipTypes[i];
@@ -1738,11 +1516,6 @@ class Model extends EmberObject {
1738
1516
  * @deprecated
1739
1517
  */
1740
1518
  static determineRelationshipType(knownSide, store) {
1741
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1742
- if (!test) {
1743
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1744
- }
1745
- })(this.modelName) : {};
1746
1519
  const knownKey = knownSide.name;
1747
1520
  const knownKind = knownSide.kind;
1748
1521
  const inverse = this.inverseFor(knownKey, store);
@@ -1790,20 +1563,9 @@ class Model extends EmberObject {
1790
1563
  @readonly
1791
1564
  */
1792
1565
  static get attributes() {
1793
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1794
- if (!test) {
1795
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1796
- }
1797
- })(this.modelName) : {};
1798
1566
  const map = new Map();
1799
1567
  this.eachComputedProperty((name, meta) => {
1800
1568
  if (isAttributeSchema(meta)) {
1801
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1802
- if (!test) {
1803
- throw new Error("You may not set 'id' as an attribute on your model. Please remove any lines that look like: `id: attr('<type>')` from " + this.toString());
1804
- }
1805
- })(name !== 'id') : {};
1806
-
1807
1569
  // TODO deprecate key being here
1808
1570
  meta.key = name;
1809
1571
  meta.name = name;
@@ -1845,11 +1607,6 @@ class Model extends EmberObject {
1845
1607
  decorateMethodV2(this, "attributes", [computeOnce]);
1846
1608
  }
1847
1609
  static get transformedAttributes() {
1848
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1849
- if (!test) {
1850
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1851
- }
1852
- })(this.modelName) : {};
1853
1610
  const map = new Map();
1854
1611
  this.eachAttribute((name, meta) => {
1855
1612
  if (meta.type) {
@@ -1895,11 +1652,6 @@ class Model extends EmberObject {
1895
1652
  decorateMethodV2(this, "transformedAttributes", [computeOnce]);
1896
1653
  }
1897
1654
  static eachAttribute(callback, binding) {
1898
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1899
- if (!test) {
1900
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1901
- }
1902
- })(this.modelName) : {};
1903
1655
  this.attributes.forEach((meta, name) => {
1904
1656
  callback.call(binding, name, meta);
1905
1657
  });
@@ -1939,11 +1691,6 @@ class Model extends EmberObject {
1939
1691
  @param {Object} [binding] the value to which the callback's `this` should be bound
1940
1692
  */
1941
1693
  static eachTransformedAttribute(callback, binding) {
1942
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1943
- if (!test) {
1944
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1945
- }
1946
- })(this.modelName) : {};
1947
1694
  this.transformedAttributes.forEach((type, name) => {
1948
1695
  callback.call(binding, name, type);
1949
1696
  });
@@ -1954,11 +1701,6 @@ class Model extends EmberObject {
1954
1701
  @public
1955
1702
  */
1956
1703
  static toString() {
1957
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
1958
- if (!test) {
1959
- throw new Error(`Accessing schema information on Models without looking up the model via the store is disallowed.`);
1960
- }
1961
- })(this.modelName) : {};
1962
1704
  return `model:${this.modelName}`;
1963
1705
  }
1964
1706
  }
@@ -1978,16 +1720,6 @@ Model.prototype.rollbackAttributes = rollbackAttributes;
1978
1720
  Model.prototype.reload = reload;
1979
1721
  defineGate(Model.prototype, 'isReloading', {
1980
1722
  get() {
1981
- deprecate(`record.isReloading is deprecated, please use store.request and either <Request> or getRequuestState to keep track of the request state instead.`, false, {
1982
- id: 'warp-drive:deprecate-legacy-request-methods',
1983
- until: '6.0',
1984
- for: '@warp-drive/core',
1985
- url: 'https://docs.warp-drive.io/api/@warp-drive/core/build-config/deprecations/variables/ENABLE_LEGACY_REQUEST_METHODS',
1986
- since: {
1987
- enabled: '5.7',
1988
- available: '5.7'
1989
- }
1990
- });
1991
1723
  return this._isReloading ?? false;
1992
1724
  },
1993
1725
  set(v) {
@@ -2019,44 +1751,6 @@ function restoreDeprecatedModelRequestBehaviors(ModelKlass) {
2019
1751
  // the values initialized during create to `setUnknownProperty`
2020
1752
  Model.prototype._createProps = null;
2021
1753
  Model.prototype._secretInit = null;
2022
- if (macroCondition(getGlobalConfig().WarpDrive.env.DEBUG)) {
2023
- const lookupDescriptor = function lookupDescriptor(obj, keyName) {
2024
- let current = obj;
2025
- do {
2026
- const descriptor = Object.getOwnPropertyDescriptor(current, keyName);
2027
- if (descriptor !== undefined) {
2028
- return descriptor;
2029
- }
2030
- current = Object.getPrototypeOf(current);
2031
- } while (current !== null);
2032
- return null;
2033
- };
2034
-
2035
- // eslint-disable-next-line @typescript-eslint/unbound-method
2036
- const init = Model.prototype.init;
2037
- Model.prototype.init = function (createArgs) {
2038
- init.call(this, createArgs);
2039
- const ourDescriptor = lookupDescriptor(Model.prototype, 'currentState');
2040
- const theirDescriptor = lookupDescriptor(this, 'currentState');
2041
- if (!ourDescriptor || !theirDescriptor) {
2042
- throw new Error(`Unable to determine if 'currentState' is a reserved property name on instances of classes extending Model. Please ensure that 'currentState' is not defined as a property on ${this.constructor.toString()}`);
2043
- }
2044
- const realState = this.___recordState;
2045
- if (ourDescriptor.get !== theirDescriptor.get || realState !== this.currentState) {
2046
- throw new Error(`'currentState' is a reserved property name on instances of classes extending Model. Please choose a different property name for ${this.constructor.toString()}`);
2047
- }
2048
- const ID_DESCRIPTOR = lookupDescriptor(Model.prototype, 'id');
2049
- const idDesc = lookupDescriptor(this, 'id');
2050
- if (!ID_DESCRIPTOR || !idDesc) {
2051
- throw new Error(`Unable to determine if 'id' is a reserved property name on instances of classes extending Model. Please ensure that 'id' is not defined as a property on ${this.constructor.toString()}`);
2052
- }
2053
- if (idDesc.get !== ID_DESCRIPTOR.get) {
2054
- throw new Error(`You may not set 'id' as an attribute on your model. Please remove any lines that look like: \`id: attr('<type>')\` from ${this.constructor.toString()}`);
2055
- }
2056
- };
2057
- delete Model.reopen;
2058
- delete Model.reopenClass;
2059
- }
2060
1754
  function isRelationshipSchema(meta) {
2061
1755
  const hasKind = typeof meta === 'object' && meta !== null && 'kind' in meta && 'options' in meta;
2062
1756
  return hasKind && (meta.kind === 'hasMany' || meta.kind === 'belongsTo');
@@ -2110,42 +1804,14 @@ class ModelSchemaProvider {
2110
1804
  return Array.from(this._schemas.keys());
2111
1805
  }
2112
1806
  hasTrait(type) {
2113
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
2114
- {
2115
- throw new Error(`hasTrait is not available with @warp-drive/legacy/model's SchemaService`);
2116
- }
2117
- })() : {};
2118
1807
  return false;
2119
1808
  }
2120
1809
  resourceHasTrait(resource, trait) {
2121
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
2122
- {
2123
- throw new Error(`resourceHasTrait is not available with @warp-drive/legacy/model's SchemaService`);
2124
- }
2125
- })() : {};
2126
1810
  return false;
2127
1811
  }
2128
- transformation(field) {
2129
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
2130
- {
2131
- throw new Error(`transformation is not available with @warp-drive/legacy/model's SchemaService`);
2132
- }
2133
- })() : {};
2134
- }
2135
- derivation(field) {
2136
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
2137
- {
2138
- throw new Error(`derivation is not available with @warp-drive/legacy/model's SchemaService`);
2139
- }
2140
- })() : {};
2141
- }
2142
- hashFn(field) {
2143
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
2144
- {
2145
- throw new Error(`hashFn is not available with @warp-drive/legacy/model's SchemaService`);
2146
- }
2147
- })() : {};
2148
- }
1812
+ transformation(field) {}
1813
+ derivation(field) {}
1814
+ hashFn(field) {}
2149
1815
  resource(resource) {
2150
1816
  const type = normalizeModelName(resource.type);
2151
1817
  if (!this._schemas.has(type)) {
@@ -2153,41 +1819,11 @@ class ModelSchemaProvider {
2153
1819
  }
2154
1820
  return this._schemas.get(type).schema;
2155
1821
  }
2156
- registerResources(schemas) {
2157
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
2158
- {
2159
- throw new Error(`registerResources is not available with @warp-drive/legacy/model's SchemaService`);
2160
- }
2161
- })() : {};
2162
- }
2163
- registerResource(schema) {
2164
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
2165
- {
2166
- throw new Error(`registerResource is not available with @warp-drive/legacy/model's SchemaService`);
2167
- }
2168
- })() : {};
2169
- }
2170
- registerTransformation(transform) {
2171
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
2172
- {
2173
- throw new Error(`registerTransformation is not available with @warp-drive/legacy/model's SchemaService`);
2174
- }
2175
- })() : {};
2176
- }
2177
- registerDerivation(derivation) {
2178
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
2179
- {
2180
- throw new Error(`registerDerivation is not available with @warp-drive/legacy/model's SchemaService`);
2181
- }
2182
- })() : {};
2183
- }
2184
- registerHashFn(hashFn) {
2185
- macroCondition(getGlobalConfig().WarpDrive.env.DEBUG) ? (test => {
2186
- {
2187
- throw new Error(`registerHashFn is not available with @warp-drive/legacy/model's SchemaService`);
2188
- }
2189
- })() : {};
2190
- }
1822
+ registerResources(schemas) {}
1823
+ registerResource(schema) {}
1824
+ registerTransformation(transform) {}
1825
+ registerDerivation(derivation) {}
1826
+ registerHashFn(hashFn) {}
2191
1827
  /** @internal */
2192
1828
  _loadModelSchema(type) {
2193
1829
  const modelClass = this.store.modelFor(type);
@@ -2244,31 +1880,13 @@ class ModelSchemaProvider {
2244
1880
  return true;
2245
1881
  }
2246
1882
  }
2247
- if (macroCondition(getGlobalConfig().WarpDrive.deprecations.ENABLE_LEGACY_SCHEMA_SERVICE)) {
1883
+ {
2248
1884
  ModelSchemaProvider.prototype.doesTypeExist = function (type) {
2249
- deprecate(`Use \`schema.hasResource({ type })\` instead of \`schema.doesTypeExist(type)\``, false, {
2250
- id: 'ember-data:schema-service-updates',
2251
- until: '6.0',
2252
- for: 'ember-data',
2253
- since: {
2254
- available: '4.13',
2255
- enabled: '5.4'
2256
- }
2257
- });
2258
1885
  return this.hasResource({
2259
1886
  type
2260
1887
  });
2261
1888
  };
2262
1889
  ModelSchemaProvider.prototype.attributesDefinitionFor = function (resource) {
2263
- deprecate(`Use \`schema.fields({ type })\` instead of \`schema.attributesDefinitionFor({ type })\``, false, {
2264
- id: 'ember-data:schema-service-updates',
2265
- until: '6.0',
2266
- for: 'ember-data',
2267
- since: {
2268
- available: '4.13',
2269
- enabled: '5.4'
2270
- }
2271
- });
2272
1890
  const type = normalizeModelName(resource.type);
2273
1891
 
2274
1892
  // @ts-expect-error intentional use of internal API
@@ -2281,15 +1899,6 @@ if (macroCondition(getGlobalConfig().WarpDrive.deprecations.ENABLE_LEGACY_SCHEMA
2281
1899
  return this._schemas.get(type).attributes;
2282
1900
  };
2283
1901
  ModelSchemaProvider.prototype.relationshipsDefinitionFor = function (resource) {
2284
- deprecate(`Use \`schema.fields({ type })\` instead of \`schema.relationshipsDefinitionFor({ type })\``, false, {
2285
- id: 'ember-data:schema-service-updates',
2286
- until: '6.0',
2287
- for: 'ember-data',
2288
- since: {
2289
- available: '4.13',
2290
- enabled: '5.4'
2291
- }
2292
- });
2293
1902
  const type = normalizeModelName(resource.type);
2294
1903
 
2295
1904
  // @ts-expect-error intentional use of internal API