File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed
main/kotlin/com/mparticle/kits
test/kotlin/com/mparticle/kits Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -248,7 +248,7 @@ class RoktKit :
248248 val userAttributes = mutableMapOf<String , String >()
249249 for ((key, value) in attributes) {
250250 val hashKey = KitUtils .hashForFiltering(key)
251- if (! kitConfiguration.mUserAttributeFilters.get(hashKey)) {
251+ if (kitConfiguration.mUserAttributeFilters.get(hashKey, true )) {
252252 userAttributes[key] = value
253253 }
254254 }
Original file line number Diff line number Diff line change @@ -359,7 +359,7 @@ class RoktKitTests {
359359 val filteredKey: String = KitUtils .hashForFiltering(" ShouldFilter" ).toString()
360360 val filteredKey2: String = KitUtils .hashForFiltering(" ShouldFilter_key_2" ).toString()
361361 jsonObject.put(filteredKey, 0 )
362- jsonObject.put(filteredKey2, 1 )
362+ jsonObject.put(filteredKey2, 0 )
363363 } catch (e: Exception ) {
364364 println (" Exception occurred: ${e.message} " )
365365 }
@@ -1012,7 +1012,7 @@ class RoktKitTests {
10121012 val filteredKey: String = KitUtils .hashForFiltering(" ShouldFilter" ).toString()
10131013 val filteredKey2: String = KitUtils .hashForFiltering(" ShouldFilter_key_2" ).toString()
10141014 jsonObject.put(filteredKey, 0 )
1015- jsonObject.put(filteredKey2, 1 )
1015+ jsonObject.put(filteredKey2, 0 )
10161016 } catch (e: Exception ) {
10171017 println (" Exception occurred: ${e.message} " )
10181018 }
Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ open class MockKitConfiguration : KitConfiguration() {
4141 override fun get (key : Int , valueIfKeyNotFound : Boolean ): Boolean {
4242 print (" SparseArray getting: $key " )
4343 return if (map.containsKey(key)) {
44- true
44+ map[key] ? : valueIfKeyNotFound
4545 } else {
4646 valueIfKeyNotFound
4747 }
You can’t perform that action at this time.
0 commit comments