openstax_accounts 7.3.0 → 7.4.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f6c2574a839a5d9ac9bca06bd2d2f4ec74c684b6
4
- data.tar.gz: 352c193b6685610b0025a67253ffc2313f84b9ca
3
+ metadata.gz: ce623db44c0708f64ebd6296553c9bb9baa85155
4
+ data.tar.gz: 912df21908f79486466243da03c45ac7a9640967
5
5
  SHA512:
6
- metadata.gz: 4d27f3a0211633e06103c3e2c033c43f6e0a421def89a601b7405e4ecc58610b4959333fc2e1da6aaecccd886416e72dfe63882ea6ffd2a9e38b5d0e55ad0b84
7
- data.tar.gz: 8847dcc227f640e2d76009919e16ed9aab8d0687083598be9f0df1979b5eeb3315524ba9d6f2df540218108d6027fb1b8e51a799182b19f33e03c2851c19dd50
6
+ metadata.gz: bdf7d0019ee853afc6cd0b295d7fc452749c61824b3ea75c1b5c3d5c10ad840b183e781e04833c720b31ff69df1e2f1c3279d5d5398fc5fc3f6618adaba7869d
7
+ data.tar.gz: 38d12dd367e42997e21f2a0be678decd4e6c1fe90c937a02c9c569a45b75520485e25436e6dd5c83fae273b4cc43c9a925cde39e7d7c70164e62e2447b348d2d
@@ -24,9 +24,11 @@ module OpenStax::Accounts
24
24
  :confirmed_faculty, :rejected_faculty]
25
25
 
26
26
  after_initialize :set_default_faculty_status
27
-
28
27
  validates :faculty_status, presence: true
29
28
 
29
+ enum role: [:unknown_role, :student, :instructor, :administrator, :librarian, :designer, :other]
30
+ validates :role, presence: true
31
+
30
32
  validates :openstax_uid, uniqueness: { allow_nil: true }
31
33
  validates :username, uniqueness: { allow_nil: true }
32
34
 
@@ -68,6 +68,22 @@ module OpenStax
68
68
  }"
69
69
  }
70
70
 
71
+ property :role,
72
+ as: :self_reported_role,
73
+ type: String,
74
+ schema_info: {
75
+ description: "The user's uncorroborated role, one of [#{
76
+ OpenStax::Accounts::Account.roles.keys.map(&:to_s).join(', ')
77
+ }]",
78
+ required: true
79
+ }
80
+
81
+ property :uuid,
82
+ type: String,
83
+ schema_info: {
84
+ description: "The UUID as set by Accounts"
85
+ }
86
+
71
87
  end
72
88
  end
73
89
  end
@@ -8,7 +8,7 @@ module OpenStax
8
8
 
9
9
  def exec(email: nil, username: nil, password: nil,
10
10
  first_name: nil, last_name: nil, full_name: nil, title: nil,
11
- salesforce_contact_id: nil, faculty_status: nil)
11
+ salesforce_contact_id: nil, faculty_status: nil, role: nil)
12
12
  raise ArgumentError,
13
13
  'You must specify either an email address or a username (and an optional password)' \
14
14
  if email.nil? && username.nil?
@@ -21,7 +21,8 @@ module OpenStax
21
21
  response = Api.find_or_create_account(
22
22
  email: email, username: username, password: password,
23
23
  first_name: first_name, last_name: last_name, full_name: full_name,
24
- salesforce_contact_id: salesforce_contact_id, faculty_status: faculty_status)
24
+ salesforce_contact_id: salesforce_contact_id, faculty_status: faculty_status,
25
+ role: role)
25
26
  fatal_error(code: :invalid_inputs) unless (200..202).include?(response.status)
26
27
 
27
28
  struct = OpenStruct.new
@@ -8,7 +8,7 @@ module OpenStax
8
8
  class SyncAccounts
9
9
 
10
10
  SYNC_ATTRIBUTES = ['username', 'first_name', 'last_name', 'full_name', 'title',
11
- 'faculty_status', 'salesforce_contact_id']
11
+ 'faculty_status', 'salesforce_contact_id', 'uuid', 'role']
12
12
 
13
13
  lev_routine transaction: :no_transaction
14
14
 
@@ -0,0 +1,9 @@
1
+ class AddUuidAndRoleToAccountsAccounts < ActiveRecord::Migration
2
+ def change
3
+ add_column :openstax_accounts_accounts, :uuid, :string
4
+ add_index :openstax_accounts_accounts, :uuid, unique: true
5
+
6
+ add_column :openstax_accounts_accounts, :role, :integer, default: 0, null: false
7
+ add_index :openstax_accounts_accounts, :role
8
+ end
9
+ end
@@ -74,12 +74,14 @@ module OpenStax
74
74
 
75
75
  # Retrieves information about accounts that have been
76
76
  # recently updated.
77
- # Results are limited to accounts that have used the current app.
77
+ # Results are limited to accounts that have used the current app, and
78
+ # limited in quantity per call by a configuration parameter.
78
79
  # Takes an options hash.
79
80
  # On failure, throws an Exception, just like the request method.
80
81
  # On success, returns an OAuth2::Response object.
81
82
  def self.get_application_account_updates(options = {})
82
- request(:get, 'application_users/updates', options)
83
+ limit = OpenStax::Accounts.configuration.max_user_updates_per_request
84
+ request(:get, "application_users/updates#{ '?limit=' + limit.to_s if !limit.blank? }", options)
83
85
  end
84
86
 
85
87
  # Marks account updates as "read".
@@ -64,6 +64,13 @@ module OpenStax
64
64
  # Which params are forwarded on the accounts login path
65
65
  attr_accessor :forwardable_login_param_keys
66
66
 
67
+ # max_user_updates_per_request
68
+ # When the user profile sync operation is called, this parameter will limit
69
+ # the number of returned profile updates from Accounts; helpful when all
70
+ # accounts have been marked as updated on Accounts so that we don't get
71
+ # overloaded.
72
+ attr_accessor :max_user_updates_per_request
73
+
67
74
  def logout_redirect_url(request)
68
75
  (@logout_redirect_url.is_a?(Proc) ?
69
76
  @logout_redirect_url.call(request) :
@@ -99,6 +106,7 @@ module OpenStax
99
106
  @logout_redirect_url = nil
100
107
  @return_to_url_approver = nil
101
108
  @forwardable_login_param_keys = [:signup_at, :go]
109
+ @max_user_updates_per_request = 250
102
110
  super
103
111
  end
104
112
 
@@ -1,5 +1,5 @@
1
1
  module OpenStax
2
2
  module Accounts
3
- VERSION = "7.3.0"
3
+ VERSION = "7.4.0"
4
4
  end
5
5
  end
Binary file
@@ -25,6 +25,8 @@ ActiveRecord::Schema.define(version: 1001) do
25
25
  t.datetime "updated_at", null: false
26
26
  t.integer "faculty_status", default: 0, null: false
27
27
  t.string "salesforce_contact_id"
28
+ t.string "uuid"
29
+ t.integer "role", default: 0, null: false
28
30
  end
29
31
 
30
32
  add_index "openstax_accounts_accounts", ["access_token"], name: "index_openstax_accounts_accounts_on_access_token", unique: true
@@ -33,8 +35,10 @@ ActiveRecord::Schema.define(version: 1001) do
33
35
  add_index "openstax_accounts_accounts", ["full_name"], name: "index_openstax_accounts_accounts_on_full_name"
34
36
  add_index "openstax_accounts_accounts", ["last_name"], name: "index_openstax_accounts_accounts_on_last_name"
35
37
  add_index "openstax_accounts_accounts", ["openstax_uid"], name: "index_openstax_accounts_accounts_on_openstax_uid", unique: true
38
+ add_index "openstax_accounts_accounts", ["role"], name: "index_openstax_accounts_accounts_on_role"
36
39
  add_index "openstax_accounts_accounts", ["salesforce_contact_id"], name: "index_openstax_accounts_accounts_on_salesforce_contact_id"
37
40
  add_index "openstax_accounts_accounts", ["username"], name: "index_openstax_accounts_accounts_on_username", unique: true
41
+ add_index "openstax_accounts_accounts", ["uuid"], name: "index_openstax_accounts_accounts_on_uuid", unique: true
38
42
 
39
43
  create_table "openstax_accounts_group_members", force: :cascade do |t|
40
44
  t.integer "group_id", null: false
Binary file
@@ -6068,3 +6068,382 @@ Migrating to CreateOwnerships (1001)
6068
6068
  WHERE name='index_users_on_account_id' AND type='index'
6069
6069
  
6070
6070
  ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
6071
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
6072
+ Migrating to AddUuidAndRoleToAccountsAccounts (9)
6073
+  (0.0ms) begin transaction
6074
+  (0.4ms) ALTER TABLE "openstax_accounts_accounts" ADD "uuid" varchar
6075
+  (0.0ms) select sqlite_version(*)
6076
+  (0.1ms)  SELECT sql
6077
+ FROM sqlite_master
6078
+ WHERE name='index_openstax_accounts_accounts_on_salesforce_contact_id' AND type='index'
6079
+ UNION ALL
6080
+ SELECT sql
6081
+ FROM sqlite_temp_master
6082
+ WHERE name='index_openstax_accounts_accounts_on_salesforce_contact_id' AND type='index'
6083
+ 
6084
+  (0.1ms) SELECT sql
6085
+ FROM sqlite_master
6086
+ WHERE name='index_openstax_accounts_accounts_on_faculty_status' AND type='index'
6087
+ UNION ALL
6088
+ SELECT sql
6089
+ FROM sqlite_temp_master
6090
+ WHERE name='index_openstax_accounts_accounts_on_faculty_status' AND type='index'
6091
+
6092
+  (0.1ms)  SELECT sql
6093
+ FROM sqlite_master
6094
+ WHERE name='index_openstax_accounts_accounts_on_full_name' AND type='index'
6095
+ UNION ALL
6096
+ SELECT sql
6097
+ FROM sqlite_temp_master
6098
+ WHERE name='index_openstax_accounts_accounts_on_full_name' AND type='index'
6099
+ 
6100
+  (0.1ms) SELECT sql
6101
+ FROM sqlite_master
6102
+ WHERE name='index_openstax_accounts_accounts_on_last_name' AND type='index'
6103
+ UNION ALL
6104
+ SELECT sql
6105
+ FROM sqlite_temp_master
6106
+ WHERE name='index_openstax_accounts_accounts_on_last_name' AND type='index'
6107
+
6108
+  (0.1ms)  SELECT sql
6109
+ FROM sqlite_master
6110
+ WHERE name='index_openstax_accounts_accounts_on_first_name' AND type='index'
6111
+ UNION ALL
6112
+ SELECT sql
6113
+ FROM sqlite_temp_master
6114
+ WHERE name='index_openstax_accounts_accounts_on_first_name' AND type='index'
6115
+ 
6116
+  (0.1ms) SELECT sql
6117
+ FROM sqlite_master
6118
+ WHERE name='index_openstax_accounts_accounts_on_access_token' AND type='index'
6119
+ UNION ALL
6120
+ SELECT sql
6121
+ FROM sqlite_temp_master
6122
+ WHERE name='index_openstax_accounts_accounts_on_access_token' AND type='index'
6123
+
6124
+  (0.1ms)  SELECT sql
6125
+ FROM sqlite_master
6126
+ WHERE name='index_openstax_accounts_accounts_on_username' AND type='index'
6127
+ UNION ALL
6128
+ SELECT sql
6129
+ FROM sqlite_temp_master
6130
+ WHERE name='index_openstax_accounts_accounts_on_username' AND type='index'
6131
+ 
6132
+  (0.1ms) SELECT sql
6133
+ FROM sqlite_master
6134
+ WHERE name='index_openstax_accounts_accounts_on_openstax_uid' AND type='index'
6135
+ UNION ALL
6136
+ SELECT sql
6137
+ FROM sqlite_temp_master
6138
+ WHERE name='index_openstax_accounts_accounts_on_openstax_uid' AND type='index'
6139
+
6140
+  (0.3ms) CREATE UNIQUE INDEX "index_openstax_accounts_accounts_on_uuid" ON "openstax_accounts_accounts" ("uuid")
6141
+  (0.1ms) ALTER TABLE "openstax_accounts_accounts" ADD "role" integer NOT NULL
6142
+  (1.0ms) rollback transaction
6143
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
6144
+ Migrating to AddUuidAndRoleToAccountsAccounts (9)
6145
+  (0.0ms) begin transaction
6146
+  (0.5ms) ALTER TABLE "openstax_accounts_accounts" ADD "uuid" varchar
6147
+  (0.0ms) select sqlite_version(*)
6148
+  (0.1ms)  SELECT sql
6149
+ FROM sqlite_master
6150
+ WHERE name='index_openstax_accounts_accounts_on_salesforce_contact_id' AND type='index'
6151
+ UNION ALL
6152
+ SELECT sql
6153
+ FROM sqlite_temp_master
6154
+ WHERE name='index_openstax_accounts_accounts_on_salesforce_contact_id' AND type='index'
6155
+ 
6156
+  (0.1ms) SELECT sql
6157
+ FROM sqlite_master
6158
+ WHERE name='index_openstax_accounts_accounts_on_faculty_status' AND type='index'
6159
+ UNION ALL
6160
+ SELECT sql
6161
+ FROM sqlite_temp_master
6162
+ WHERE name='index_openstax_accounts_accounts_on_faculty_status' AND type='index'
6163
+
6164
+  (0.1ms)  SELECT sql
6165
+ FROM sqlite_master
6166
+ WHERE name='index_openstax_accounts_accounts_on_full_name' AND type='index'
6167
+ UNION ALL
6168
+ SELECT sql
6169
+ FROM sqlite_temp_master
6170
+ WHERE name='index_openstax_accounts_accounts_on_full_name' AND type='index'
6171
+ 
6172
+  (0.1ms) SELECT sql
6173
+ FROM sqlite_master
6174
+ WHERE name='index_openstax_accounts_accounts_on_last_name' AND type='index'
6175
+ UNION ALL
6176
+ SELECT sql
6177
+ FROM sqlite_temp_master
6178
+ WHERE name='index_openstax_accounts_accounts_on_last_name' AND type='index'
6179
+
6180
+  (0.1ms)  SELECT sql
6181
+ FROM sqlite_master
6182
+ WHERE name='index_openstax_accounts_accounts_on_first_name' AND type='index'
6183
+ UNION ALL
6184
+ SELECT sql
6185
+ FROM sqlite_temp_master
6186
+ WHERE name='index_openstax_accounts_accounts_on_first_name' AND type='index'
6187
+ 
6188
+  (0.1ms) SELECT sql
6189
+ FROM sqlite_master
6190
+ WHERE name='index_openstax_accounts_accounts_on_access_token' AND type='index'
6191
+ UNION ALL
6192
+ SELECT sql
6193
+ FROM sqlite_temp_master
6194
+ WHERE name='index_openstax_accounts_accounts_on_access_token' AND type='index'
6195
+
6196
+  (0.1ms)  SELECT sql
6197
+ FROM sqlite_master
6198
+ WHERE name='index_openstax_accounts_accounts_on_username' AND type='index'
6199
+ UNION ALL
6200
+ SELECT sql
6201
+ FROM sqlite_temp_master
6202
+ WHERE name='index_openstax_accounts_accounts_on_username' AND type='index'
6203
+ 
6204
+  (0.1ms) SELECT sql
6205
+ FROM sqlite_master
6206
+ WHERE name='index_openstax_accounts_accounts_on_openstax_uid' AND type='index'
6207
+ UNION ALL
6208
+ SELECT sql
6209
+ FROM sqlite_temp_master
6210
+ WHERE name='index_openstax_accounts_accounts_on_openstax_uid' AND type='index'
6211
+
6212
+  (0.3ms) CREATE UNIQUE INDEX "index_openstax_accounts_accounts_on_uuid" ON "openstax_accounts_accounts" ("uuid")
6213
+  (0.2ms) ALTER TABLE "openstax_accounts_accounts" ADD "role" integer DEFAULT 0 NOT NULL
6214
+  (0.1ms)  SELECT sql
6215
+ FROM sqlite_master
6216
+ WHERE name='index_openstax_accounts_accounts_on_uuid' AND type='index'
6217
+ UNION ALL
6218
+ SELECT sql
6219
+ FROM sqlite_temp_master
6220
+ WHERE name='index_openstax_accounts_accounts_on_uuid' AND type='index'
6221
+ 
6222
+  (0.1ms) SELECT sql
6223
+ FROM sqlite_master
6224
+ WHERE name='index_openstax_accounts_accounts_on_salesforce_contact_id' AND type='index'
6225
+ UNION ALL
6226
+ SELECT sql
6227
+ FROM sqlite_temp_master
6228
+ WHERE name='index_openstax_accounts_accounts_on_salesforce_contact_id' AND type='index'
6229
+
6230
+  (0.1ms)  SELECT sql
6231
+ FROM sqlite_master
6232
+ WHERE name='index_openstax_accounts_accounts_on_faculty_status' AND type='index'
6233
+ UNION ALL
6234
+ SELECT sql
6235
+ FROM sqlite_temp_master
6236
+ WHERE name='index_openstax_accounts_accounts_on_faculty_status' AND type='index'
6237
+ 
6238
+  (0.1ms) SELECT sql
6239
+ FROM sqlite_master
6240
+ WHERE name='index_openstax_accounts_accounts_on_full_name' AND type='index'
6241
+ UNION ALL
6242
+ SELECT sql
6243
+ FROM sqlite_temp_master
6244
+ WHERE name='index_openstax_accounts_accounts_on_full_name' AND type='index'
6245
+
6246
+  (0.1ms)  SELECT sql
6247
+ FROM sqlite_master
6248
+ WHERE name='index_openstax_accounts_accounts_on_last_name' AND type='index'
6249
+ UNION ALL
6250
+ SELECT sql
6251
+ FROM sqlite_temp_master
6252
+ WHERE name='index_openstax_accounts_accounts_on_last_name' AND type='index'
6253
+ 
6254
+  (0.1ms) SELECT sql
6255
+ FROM sqlite_master
6256
+ WHERE name='index_openstax_accounts_accounts_on_first_name' AND type='index'
6257
+ UNION ALL
6258
+ SELECT sql
6259
+ FROM sqlite_temp_master
6260
+ WHERE name='index_openstax_accounts_accounts_on_first_name' AND type='index'
6261
+
6262
+  (0.1ms)  SELECT sql
6263
+ FROM sqlite_master
6264
+ WHERE name='index_openstax_accounts_accounts_on_access_token' AND type='index'
6265
+ UNION ALL
6266
+ SELECT sql
6267
+ FROM sqlite_temp_master
6268
+ WHERE name='index_openstax_accounts_accounts_on_access_token' AND type='index'
6269
+ 
6270
+  (0.1ms) SELECT sql
6271
+ FROM sqlite_master
6272
+ WHERE name='index_openstax_accounts_accounts_on_username' AND type='index'
6273
+ UNION ALL
6274
+ SELECT sql
6275
+ FROM sqlite_temp_master
6276
+ WHERE name='index_openstax_accounts_accounts_on_username' AND type='index'
6277
+
6278
+  (0.1ms)  SELECT sql
6279
+ FROM sqlite_master
6280
+ WHERE name='index_openstax_accounts_accounts_on_openstax_uid' AND type='index'
6281
+ UNION ALL
6282
+ SELECT sql
6283
+ FROM sqlite_temp_master
6284
+ WHERE name='index_openstax_accounts_accounts_on_openstax_uid' AND type='index'
6285
+ 
6286
+  (0.1ms) CREATE INDEX "index_openstax_accounts_accounts_on_role" ON "openstax_accounts_accounts" ("role")
6287
+ SQL (0.1ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "9"]]
6288
+  (1.1ms) commit transaction
6289
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
6290
+  (0.1ms) SELECT sql
6291
+ FROM sqlite_master
6292
+ WHERE name='index_openstax_accounts_accounts_on_role' AND type='index'
6293
+ UNION ALL
6294
+ SELECT sql
6295
+ FROM sqlite_temp_master
6296
+ WHERE name='index_openstax_accounts_accounts_on_role' AND type='index'
6297
+
6298
+  (0.1ms)  SELECT sql
6299
+ FROM sqlite_master
6300
+ WHERE name='index_openstax_accounts_accounts_on_uuid' AND type='index'
6301
+ UNION ALL
6302
+ SELECT sql
6303
+ FROM sqlite_temp_master
6304
+ WHERE name='index_openstax_accounts_accounts_on_uuid' AND type='index'
6305
+ 
6306
+  (0.1ms) SELECT sql
6307
+ FROM sqlite_master
6308
+ WHERE name='index_openstax_accounts_accounts_on_salesforce_contact_id' AND type='index'
6309
+ UNION ALL
6310
+ SELECT sql
6311
+ FROM sqlite_temp_master
6312
+ WHERE name='index_openstax_accounts_accounts_on_salesforce_contact_id' AND type='index'
6313
+
6314
+  (0.1ms)  SELECT sql
6315
+ FROM sqlite_master
6316
+ WHERE name='index_openstax_accounts_accounts_on_faculty_status' AND type='index'
6317
+ UNION ALL
6318
+ SELECT sql
6319
+ FROM sqlite_temp_master
6320
+ WHERE name='index_openstax_accounts_accounts_on_faculty_status' AND type='index'
6321
+ 
6322
+  (0.1ms) SELECT sql
6323
+ FROM sqlite_master
6324
+ WHERE name='index_openstax_accounts_accounts_on_full_name' AND type='index'
6325
+ UNION ALL
6326
+ SELECT sql
6327
+ FROM sqlite_temp_master
6328
+ WHERE name='index_openstax_accounts_accounts_on_full_name' AND type='index'
6329
+
6330
+  (0.1ms)  SELECT sql
6331
+ FROM sqlite_master
6332
+ WHERE name='index_openstax_accounts_accounts_on_last_name' AND type='index'
6333
+ UNION ALL
6334
+ SELECT sql
6335
+ FROM sqlite_temp_master
6336
+ WHERE name='index_openstax_accounts_accounts_on_last_name' AND type='index'
6337
+ 
6338
+  (0.1ms) SELECT sql
6339
+ FROM sqlite_master
6340
+ WHERE name='index_openstax_accounts_accounts_on_first_name' AND type='index'
6341
+ UNION ALL
6342
+ SELECT sql
6343
+ FROM sqlite_temp_master
6344
+ WHERE name='index_openstax_accounts_accounts_on_first_name' AND type='index'
6345
+
6346
+  (0.1ms)  SELECT sql
6347
+ FROM sqlite_master
6348
+ WHERE name='index_openstax_accounts_accounts_on_access_token' AND type='index'
6349
+ UNION ALL
6350
+ SELECT sql
6351
+ FROM sqlite_temp_master
6352
+ WHERE name='index_openstax_accounts_accounts_on_access_token' AND type='index'
6353
+ 
6354
+  (0.1ms) SELECT sql
6355
+ FROM sqlite_master
6356
+ WHERE name='index_openstax_accounts_accounts_on_username' AND type='index'
6357
+ UNION ALL
6358
+ SELECT sql
6359
+ FROM sqlite_temp_master
6360
+ WHERE name='index_openstax_accounts_accounts_on_username' AND type='index'
6361
+
6362
+  (0.1ms)  SELECT sql
6363
+ FROM sqlite_master
6364
+ WHERE name='index_openstax_accounts_accounts_on_openstax_uid' AND type='index'
6365
+ UNION ALL
6366
+ SELECT sql
6367
+ FROM sqlite_temp_master
6368
+ WHERE name='index_openstax_accounts_accounts_on_openstax_uid' AND type='index'
6369
+ 
6370
+  (0.1ms) SELECT sql
6371
+ FROM sqlite_master
6372
+ WHERE name='index_openstax_accounts_group_members_on_user_id' AND type='index'
6373
+ UNION ALL
6374
+ SELECT sql
6375
+ FROM sqlite_temp_master
6376
+ WHERE name='index_openstax_accounts_group_members_on_user_id' AND type='index'
6377
+
6378
+  (0.1ms)  SELECT sql
6379
+ FROM sqlite_master
6380
+ WHERE name='index_openstax_accounts_group_members_on_group_id_and_user_id' AND type='index'
6381
+ UNION ALL
6382
+ SELECT sql
6383
+ FROM sqlite_temp_master
6384
+ WHERE name='index_openstax_accounts_group_members_on_group_id_and_user_id' AND type='index'
6385
+ 
6386
+  (0.1ms) SELECT sql
6387
+ FROM sqlite_master
6388
+ WHERE name='index_openstax_accounts_group_nestings_on_container_group_id' AND type='index'
6389
+ UNION ALL
6390
+ SELECT sql
6391
+ FROM sqlite_temp_master
6392
+ WHERE name='index_openstax_accounts_group_nestings_on_container_group_id' AND type='index'
6393
+
6394
+  (0.1ms)  SELECT sql
6395
+ FROM sqlite_master
6396
+ WHERE name='index_openstax_accounts_group_nestings_on_member_group_id' AND type='index'
6397
+ UNION ALL
6398
+ SELECT sql
6399
+ FROM sqlite_temp_master
6400
+ WHERE name='index_openstax_accounts_group_nestings_on_member_group_id' AND type='index'
6401
+ 
6402
+  (0.1ms) SELECT sql
6403
+ FROM sqlite_master
6404
+ WHERE name='index_openstax_accounts_group_owners_on_user_id' AND type='index'
6405
+ UNION ALL
6406
+ SELECT sql
6407
+ FROM sqlite_temp_master
6408
+ WHERE name='index_openstax_accounts_group_owners_on_user_id' AND type='index'
6409
+
6410
+  (0.1ms)  SELECT sql
6411
+ FROM sqlite_master
6412
+ WHERE name='index_openstax_accounts_group_owners_on_group_id_and_user_id' AND type='index'
6413
+ UNION ALL
6414
+ SELECT sql
6415
+ FROM sqlite_temp_master
6416
+ WHERE name='index_openstax_accounts_group_owners_on_group_id_and_user_id' AND type='index'
6417
+ 
6418
+  (0.1ms) SELECT sql
6419
+ FROM sqlite_master
6420
+ WHERE name='index_openstax_accounts_groups_on_is_public' AND type='index'
6421
+ UNION ALL
6422
+ SELECT sql
6423
+ FROM sqlite_temp_master
6424
+ WHERE name='index_openstax_accounts_groups_on_is_public' AND type='index'
6425
+
6426
+  (0.1ms)  SELECT sql
6427
+ FROM sqlite_master
6428
+ WHERE name='index_openstax_accounts_groups_on_openstax_uid' AND type='index'
6429
+ UNION ALL
6430
+ SELECT sql
6431
+ FROM sqlite_temp_master
6432
+ WHERE name='index_openstax_accounts_groups_on_openstax_uid' AND type='index'
6433
+ 
6434
+  (0.1ms) SELECT sql
6435
+ FROM sqlite_master
6436
+ WHERE name='index_ownerships_on_owner_id_and_owner_type' AND type='index'
6437
+ UNION ALL
6438
+ SELECT sql
6439
+ FROM sqlite_temp_master
6440
+ WHERE name='index_ownerships_on_owner_id_and_owner_type' AND type='index'
6441
+
6442
+  (0.1ms)  SELECT sql
6443
+ FROM sqlite_master
6444
+ WHERE name='index_users_on_account_id' AND type='index'
6445
+ UNION ALL
6446
+ SELECT sql
6447
+ FROM sqlite_temp_master
6448
+ WHERE name='index_users_on_account_id' AND type='index'
6449
+