Skip to content

Commit

Permalink
Made the reference to 'Iterable' use a fully qualified ref 'System.It…
Browse files Browse the repository at this point in the history
…erable', added a name-shadow class for 'Iterable'

This ensures Nebula Logger can be installed/works correctly in orgs that decide to use name-shadowing
  • Loading branch information
jongpie committed Nov 7, 2024
1 parent f36ccd2 commit 92aa6a5
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -467,7 +467,7 @@ global with sharing class LogEntryEventBuilder {
* @param recordsIds The Set of `SObject` records ids related to the entry. Will be converted to list and the JSON of the list is automatically added to the entry
* @return The same instance of `LogEntryEventBuilder`, useful for chaining methods
*/
global LogEntryEventBuilder setRecord(Iterable<Id> recordsIds) {
global LogEntryEventBuilder setRecord(System.Iterable<Id> recordsIds) {
if (this.shouldSave() == false) {
return this;
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
//------------------------------------------------------------------------------------------------//
// This file is part of the Nebula Logger project, released under the MIT License. //
// See LICENSE file or go to https://github.com/jongpie/NebulaLogger for full license details. //
//------------------------------------------------------------------------------------------------//

// This class intentionally does nothing - it's here to ensure that any references
// in Nebula Logger's codebase use `System.Iterable` instead of just `Iterable`
@SuppressWarnings('PMD.ApexDoc, PMD.EmptyStatementBlock')
public without sharing class Iterable {
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>61.0</apiVersion>
<status>Active</status>
</ApexClass>

0 comments on commit 92aa6a5

Please sign in to comment.